diff --git a/.travis.yml b/.travis.yml index 748f026..2ab25bf 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,4 +8,4 @@ script: - bundle install --path vendor/bundle - bundle exec rspec - gem build dropbox-sign.gemspec - - gem install ./dropbox-sign-1.10.0.gem + - gem install ./dropbox-sign-1.11.0.gem diff --git a/Gemfile.lock b/Gemfile.lock index 5b520e4..5bdd7c8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - dropbox-sign (1.10.0) + dropbox-sign (1.11.0) typhoeus (~> 1.0, >= 1.0.1) GEM @@ -11,17 +11,19 @@ GEM byebug (11.1.3) coderay (1.1.3) diff-lcs (1.5.1) - ethon (0.16.0) + ethon (0.18.0) ffi (>= 1.15.0) - ffi (1.17.2-aarch64-linux-gnu) - ffi (1.17.2-arm64-darwin) - ffi (1.17.2-x86_64-darwin) - ffi (1.17.2-x86_64-linux-gnu) + logger + ffi (1.17.4-aarch64-linux-gnu) + ffi (1.17.4-arm64-darwin) + ffi (1.17.4-x86_64-darwin) + ffi (1.17.4-x86_64-linux-gnu) json (2.7.2) json_spec (1.1.5) multi_json (~> 1.0) rspec (>= 2.0, < 4.0) language_server-protocol (3.17.0.3) + logger (1.7.0) method_source (1.1.0) multi_json (1.15.0) parallel (1.26.3) @@ -64,8 +66,8 @@ GEM rubocop-ast (1.32.3) parser (>= 3.3.1.0) ruby-progressbar (1.13.0) - typhoeus (1.4.1) - ethon (>= 0.9.0) + typhoeus (1.6.0) + ethon (>= 0.18.0) unicode-display_width (2.5.0) PLATFORMS diff --git a/README.md b/README.md index 370dd5a..0b9f467 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ directory that corresponds to the file you want updated. This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: - API version: 3.0.0 -- Package version: 1.10.0 +- Package version: 1.11.0 - Generator version: 7.12.0 - Build package: org.openapitools.codegen.languages.RubyClientCodegen @@ -47,15 +47,15 @@ gem build dropbox-sign.gemspec Then install the gem locally: ```shell -gem install ./dropbox-sign-1.10.0.gem +gem install ./dropbox-sign-1.11.0.gem ``` -(for development, run `gem install --dev ./dropbox-sign-1.10.0.gem` to install the development dependencies) +(for development, run `gem install --dev ./dropbox-sign-1.11.0.gem` to install the development dependencies) Finally add this to the Gemfile: - gem 'dropbox-sign', '~> 1.10.0' + gem 'dropbox-sign', '~> 1.11.0' ### Install from Git @@ -189,6 +189,7 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::AccountGetResponse](docs/AccountGetResponse.md) - [Dropbox::Sign::AccountResponse](docs/AccountResponse.md) - [Dropbox::Sign::AccountResponseQuotas](docs/AccountResponseQuotas.md) + - [Dropbox::Sign::AccountResponseSettings](docs/AccountResponseSettings.md) - [Dropbox::Sign::AccountResponseUsage](docs/AccountResponseUsage.md) - [Dropbox::Sign::AccountUpdateRequest](docs/AccountUpdateRequest.md) - [Dropbox::Sign::AccountVerifyRequest](docs/AccountVerifyRequest.md) @@ -332,7 +333,6 @@ All URIs are relative to *https://api.hellosign.com/v3* - [Dropbox::Sign::TemplateCreateRequest](docs/TemplateCreateRequest.md) - [Dropbox::Sign::TemplateCreateResponse](docs/TemplateCreateResponse.md) - [Dropbox::Sign::TemplateCreateResponseTemplate](docs/TemplateCreateResponseTemplate.md) - - [Dropbox::Sign::TemplateEditResponse](docs/TemplateEditResponse.md) - [Dropbox::Sign::TemplateGetResponse](docs/TemplateGetResponse.md) - [Dropbox::Sign::TemplateListResponse](docs/TemplateListResponse.md) - [Dropbox::Sign::TemplateRemoveUserRequest](docs/TemplateRemoveUserRequest.md) diff --git a/VERSION b/VERSION index 81c871d..1cac385 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.10.0 +1.11.0 diff --git a/docs/AccountResponse.md b/docs/AccountResponse.md index 294f294..aeb1b38 100644 --- a/docs/AccountResponse.md +++ b/docs/AccountResponse.md @@ -17,4 +17,5 @@ | `team_id` | ```String``` | The id of the team account belongs to. | | | `locale` | ```String``` | The locale used in this Account. Check out the list of [supported locales](/api/reference/constants/#supported-locales) to learn more about the possible values. | | | `usage` | [```AccountResponseUsage```](AccountResponseUsage.md) | | | +| `settings` | [```AccountResponseSettings```](AccountResponseSettings.md) | | | diff --git a/docs/AccountResponseSettings.md b/docs/AccountResponseSettings.md new file mode 100644 index 0000000..642280e --- /dev/null +++ b/docs/AccountResponseSettings.md @@ -0,0 +1,12 @@ +# Dropbox::Sign::AccountResponseSettings + +Subset of configured settings + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| `signer_access_codes` | ```Boolean``` | Returns `true` if _Custom access codes_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). | | +| `sms_delivery` | ```Boolean``` | Returns `true` if _Text message_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). | | +| `sms_authentication` | ```Boolean``` | Returns `true` if _Signer authentication_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). | | + diff --git a/docs/SignatureRequestApi.md b/docs/SignatureRequestApi.md index 964273c..e3f4b36 100644 --- a/docs/SignatureRequestApi.md +++ b/docs/SignatureRequestApi.md @@ -390,6 +390,7 @@ signing_options.draw = true signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestSigner.new signers_1.name = "Jack" @@ -497,6 +498,7 @@ signing_options.draw = true signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestTemplateSigner.new signers_1.role = "Client" @@ -1609,6 +1611,7 @@ signing_options.draw = true signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestSigner.new signers_1.name = "Jack" @@ -1723,6 +1726,7 @@ signing_options.draw = true signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestTemplateSigner.new signers_1.role = "Client" diff --git a/docs/SignatureRequestEditRequest.md b/docs/SignatureRequestEditRequest.md index 39d575a..ce53250 100644 --- a/docs/SignatureRequestEditRequest.md +++ b/docs/SignatureRequestEditRequest.md @@ -21,7 +21,7 @@ | `form_field_rules` | [```Array```](SubFormFieldRule.md) | Conditional Logic rules for fields defined in `form_fields_per_document`. | | | `form_fields_per_document` | [```Array```](SubFormFieldsPerDocumentBase.md) | The fields that should appear on the document, expressed as an array of objects. (For more details you can read about it here: [Using Form Fields per Document](/docs/openapi/form-fields-per-document).)

**NOTE:** Fields like **text**, **dropdown**, **checkbox**, **radio**, and **hyperlink** have additional required and optional parameters. Check out the list of [additional parameters](/api/reference/constants/#form-fields-per-document) for these field types.

* Text Field use `SubFormFieldsPerDocumentText`
* Dropdown Field use `SubFormFieldsPerDocumentDropdown`
* Hyperlink Field use `SubFormFieldsPerDocumentHyperlink`
* Checkbox Field use `SubFormFieldsPerDocumentCheckbox`
* Radio Field use `SubFormFieldsPerDocumentRadio`
* Signature Field use `SubFormFieldsPerDocumentSignature`
* Date Signed Field use `SubFormFieldsPerDocumentDateSigned`
* Initials Field use `SubFormFieldsPerDocumentInitials`
* Text Merge Field use `SubFormFieldsPerDocumentTextMerge`
* Checkbox Merge Field use `SubFormFieldsPerDocumentCheckboxMerge` | | | `hide_text_tags` | ```Boolean``` | Enables automatic Text Tag removal when set to true.

**NOTE:** Removing text tags this way can cause unwanted clipping. We recommend leaving this setting on `false` and instead hiding your text tags using white text or a similar approach. See the [Text Tags Walkthrough](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) for more information. | [default to false] | -| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | +| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Hash``` | Key-value data that should be attached to the signature request. This metadata is included in all API responses and events involving the signature request. For example, use the metadata field to store a signer's order number for look up when receiving events for the signature request.

Each request can include up to 10 metadata keys (or 50 nested metadata keys), with key names up to 40 characters long and values up to 1000 characters long. | | | `signing_options` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestEditWithTemplateRequest.md b/docs/SignatureRequestEditWithTemplateRequest.md index 12b4bee..f4391eb 100644 --- a/docs/SignatureRequestEditWithTemplateRequest.md +++ b/docs/SignatureRequestEditWithTemplateRequest.md @@ -14,7 +14,7 @@ | `custom_fields` | [```Array```](SubCustomField.md) | An array defining values and options for custom fields. Required when a custom field exists in the Template. | | | `files` | ```Array``` | Use `files[]` to indicate the uploaded file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | | `file_urls` | ```Array``` | Use `file_urls[]` to have Dropbox Sign download the file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | -| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | +| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Hash``` | Key-value data that should be attached to the signature request. This metadata is included in all API responses and events involving the signature request. For example, use the metadata field to store a signer's order number for look up when receiving events for the signature request.

Each request can include up to 10 metadata keys (or 50 nested metadata keys), with key names up to 40 characters long and values up to 1000 characters long. | | | `signing_options` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestSendRequest.md b/docs/SignatureRequestSendRequest.md index 683075e..ca6f167 100644 --- a/docs/SignatureRequestSendRequest.md +++ b/docs/SignatureRequestSendRequest.md @@ -22,7 +22,7 @@ | `form_fields_per_document` | [```Array```](SubFormFieldsPerDocumentBase.md) | The fields that should appear on the document, expressed as an array of objects. (For more details you can read about it here: [Using Form Fields per Document](/docs/openapi/form-fields-per-document).)

**NOTE:** Fields like **text**, **dropdown**, **checkbox**, **radio**, and **hyperlink** have additional required and optional parameters. Check out the list of [additional parameters](/api/reference/constants/#form-fields-per-document) for these field types.

* Text Field use `SubFormFieldsPerDocumentText`
* Dropdown Field use `SubFormFieldsPerDocumentDropdown`
* Hyperlink Field use `SubFormFieldsPerDocumentHyperlink`
* Checkbox Field use `SubFormFieldsPerDocumentCheckbox`
* Radio Field use `SubFormFieldsPerDocumentRadio`
* Signature Field use `SubFormFieldsPerDocumentSignature`
* Date Signed Field use `SubFormFieldsPerDocumentDateSigned`
* Initials Field use `SubFormFieldsPerDocumentInitials`
* Text Merge Field use `SubFormFieldsPerDocumentTextMerge`
* Checkbox Merge Field use `SubFormFieldsPerDocumentCheckboxMerge` | | | `hide_text_tags` | ```Boolean``` | Enables automatic Text Tag removal when set to true.

**NOTE:** Removing text tags this way can cause unwanted clipping. We recommend leaving this setting on `false` and instead hiding your text tags using white text or a similar approach. See the [Text Tags Walkthrough](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) for more information. | [default to false] | | `is_qualified_signature` | ```Boolean``` | Send with a value of `true` if you wish to enable [Qualified Electronic Signatures](https://www.hellosign.com/features/qualified-electronic-signatures) (QES), which requires a face-to-face call to verify the signer's identity.<br>
**NOTE:** QES is only available on the Premium API plan as an add-on purchase. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | -| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | +| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Hash``` | Key-value data that should be attached to the signature request. This metadata is included in all API responses and events involving the signature request. For example, use the metadata field to store a signer's order number for look up when receiving events for the signature request.

Each request can include up to 10 metadata keys (or 50 nested metadata keys), with key names up to 40 characters long and values up to 1000 characters long. | | | `signing_options` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestSendWithTemplateRequest.md b/docs/SignatureRequestSendWithTemplateRequest.md index 94e17b8..39b1652 100644 --- a/docs/SignatureRequestSendWithTemplateRequest.md +++ b/docs/SignatureRequestSendWithTemplateRequest.md @@ -15,7 +15,7 @@ | `files` | ```Array``` | Use `files[]` to indicate the uploaded file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | | `file_urls` | ```Array``` | Use `file_urls[]` to have Dropbox Sign download the file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | | `is_qualified_signature` | ```Boolean``` | Send with a value of `true` if you wish to enable [Qualified Electronic Signatures](https://www.hellosign.com/features/qualified-electronic-signatures) (QES), which requires a face-to-face call to verify the signer's identity.<br>
**NOTE:** QES is only available on the Premium API plan as an add-on purchase. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | -| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | +| `is_eid` | ```Boolean``` | Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br>
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. | [default to false] | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Hash``` | Key-value data that should be attached to the signature request. This metadata is included in all API responses and events involving the signature request. For example, use the metadata field to store a signer's order number for look up when receiving events for the signature request.

Each request can include up to 10 metadata keys (or 50 nested metadata keys), with key names up to 40 characters long and values up to 1000 characters long. | | | `signing_options` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SubSigningOptions.md b/docs/SubSigningOptions.md index d2eb449..026659a 100644 --- a/docs/SubSigningOptions.md +++ b/docs/SubSigningOptions.md @@ -1,9 +1,11 @@ # Dropbox::Sign::SubSigningOptions -This allows the requester to specify the types allowed for creating a signature. +This allows the requester to specify the types allowed for creating a signature and specify another signing options. **NOTE:** If `signing_options` are not defined in the request, the allowed types will default to those specified in the account settings. +**NOTE:** If `force_advanced_signature_details` is set, allowed types has to be defined too. + ## Properties | Name | Type | Description | Notes | @@ -13,4 +15,5 @@ This allows the requester to specify the types allowed for creating a signature. | `phone` | ```Boolean``` | Allows using a smartphone to email the signature | [default to false] | | `type` | ```Boolean``` | Allows typing the signature | [default to false] | | `upload` | ```Boolean``` | Allows uploading the signature | [default to false] | +| `force_advanced_signature_details` | ```Boolean``` | Turning on advanced signature details for the signature request | [default to false] | diff --git a/docs/TemplateApi.md b/docs/TemplateApi.md index 315ced9..ffd6ec0 100644 --- a/docs/TemplateApi.md +++ b/docs/TemplateApi.md @@ -97,7 +97,7 @@ end Create Template -Creates a template that can then be used. +Creates a template that can be used in future signature requests. If `client_id` is provided, the template will be created as an embedded template. Embedded templates can be used for embedded signature requests and can be edited later by generating a new `edit_url` with [/embedded/edit_url/{template_id}](/api/reference/operation/embeddedEditUrl/). Template creation may complete asynchronously after the initial request is accepted. It is recommended that a callback be implemented to listen for the callback event. A `template_created` event indicates the template is ready to use, while a `template_error` event indicates there was a problem while creating the template. If a callback handler has been configured and the event has not been received within 60 minutes of making the call, check the status of the request in the API dashboard and retry the request if necessary. ### Examples diff --git a/docs/TemplateEditResponse.md b/docs/TemplateEditResponse.md deleted file mode 100644 index 5b46080..0000000 --- a/docs/TemplateEditResponse.md +++ /dev/null @@ -1,10 +0,0 @@ -# Dropbox::Sign::TemplateEditResponse - - - -## Properties - -| Name | Type | Description | Notes | -| ---- | ---- | ----------- | ----- | -| `template_id`*_required_ | ```String``` | The id of the Template. | | - diff --git a/examples/SignatureRequestCreateEmbeddedExample.rb b/examples/SignatureRequestCreateEmbeddedExample.rb index 9be4112..b3d0c87 100644 --- a/examples/SignatureRequestCreateEmbeddedExample.rb +++ b/examples/SignatureRequestCreateEmbeddedExample.rb @@ -12,6 +12,7 @@ signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestSigner.new signers_1.name = "Jack" diff --git a/examples/SignatureRequestCreateEmbeddedWithTemplateExample.rb b/examples/SignatureRequestCreateEmbeddedWithTemplateExample.rb index dbcd4af..1091be1 100644 --- a/examples/SignatureRequestCreateEmbeddedWithTemplateExample.rb +++ b/examples/SignatureRequestCreateEmbeddedWithTemplateExample.rb @@ -12,6 +12,7 @@ signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestTemplateSigner.new signers_1.role = "Client" diff --git a/examples/SignatureRequestSendExample.rb b/examples/SignatureRequestSendExample.rb index 270ebe0..05777f5 100644 --- a/examples/SignatureRequestSendExample.rb +++ b/examples/SignatureRequestSendExample.rb @@ -15,6 +15,7 @@ signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestSigner.new signers_1.name = "Jack" diff --git a/examples/SignatureRequestSendWithTemplateExample.rb b/examples/SignatureRequestSendWithTemplateExample.rb index 24fd0de..2ca41c1 100644 --- a/examples/SignatureRequestSendWithTemplateExample.rb +++ b/examples/SignatureRequestSendWithTemplateExample.rb @@ -12,6 +12,7 @@ signing_options.phone = false signing_options.type = true signing_options.upload = true +signing_options.force_advanced_signature_details = false signers_1 = Dropbox::Sign::SubSignatureRequestTemplateSigner.new signers_1.role = "Client" diff --git a/lib/dropbox-sign.rb b/lib/dropbox-sign.rb index 413c293..e85d1d5 100644 --- a/lib/dropbox-sign.rb +++ b/lib/dropbox-sign.rb @@ -22,6 +22,7 @@ require 'dropbox-sign/models/account_get_response' require 'dropbox-sign/models/account_response' require 'dropbox-sign/models/account_response_quotas' +require 'dropbox-sign/models/account_response_settings' require 'dropbox-sign/models/account_response_usage' require 'dropbox-sign/models/account_update_request' require 'dropbox-sign/models/account_verify_request' @@ -144,7 +145,6 @@ require 'dropbox-sign/models/template_create_request' require 'dropbox-sign/models/template_create_response' require 'dropbox-sign/models/template_create_response_template' -require 'dropbox-sign/models/template_edit_response' require 'dropbox-sign/models/template_get_response' require 'dropbox-sign/models/template_list_response' require 'dropbox-sign/models/template_remove_user_request' diff --git a/lib/dropbox-sign/api/template_api.rb b/lib/dropbox-sign/api/template_api.rb index 4620ab3..c43bf9e 100644 --- a/lib/dropbox-sign/api/template_api.rb +++ b/lib/dropbox-sign/api/template_api.rb @@ -138,7 +138,7 @@ def template_add_user_with_http_info(template_id, template_add_user_request, opt end # Create Template - # Creates a template that can then be used. + # Creates a template that can be used in future signature requests. If `client_id` is provided, the template will be created as an embedded template. Embedded templates can be used for embedded signature requests and can be edited later by generating a new `edit_url` with [/embedded/edit_url/{template_id}](/api/reference/operation/embeddedEditUrl/). Template creation may complete asynchronously after the initial request is accepted. It is recommended that a callback be implemented to listen for the callback event. A `template_created` event indicates the template is ready to use, while a `template_error` event indicates there was a problem while creating the template. If a callback handler has been configured and the event has not been received within 60 minutes of making the call, check the status of the request in the API dashboard and retry the request if necessary. # @param template_create_request [TemplateCreateRequest] # @param [Hash] opts the optional parameters # @return [TemplateCreateResponse] @@ -148,7 +148,7 @@ def template_create(template_create_request, opts = {}) end # Create Template - # Creates a template that can then be used. + # Creates a template that can be used in future signature requests. If `client_id` is provided, the template will be created as an embedded template. Embedded templates can be used for embedded signature requests and can be edited later by generating a new `edit_url` with [/embedded/edit_url/{template_id}](/api/reference/operation/embeddedEditUrl/). Template creation may complete asynchronously after the initial request is accepted. It is recommended that a callback be implemented to listen for the callback event. A `template_created` event indicates the template is ready to use, while a `template_error` event indicates there was a problem while creating the template. If a callback handler has been configured and the event has not been received within 60 minutes of making the call, check the status of the request in the API dashboard and retry the request if necessary. # @param template_create_request [TemplateCreateRequest] # @param [Hash] opts the optional parameters # @return [Array<(TemplateCreateResponse, Integer, Hash)>] TemplateCreateResponse data, response status code and response headers diff --git a/lib/dropbox-sign/api_client.rb b/lib/dropbox-sign/api_client.rb index ad1d842..bd7e736 100644 --- a/lib/dropbox-sign/api_client.rb +++ b/lib/dropbox-sign/api_client.rb @@ -132,6 +132,22 @@ def build_request(http_method, path, opts = {}) end end + # Workaround for the Typhoeus/libcurl multipart PUT bug. + # libcurl only builds a multipart body via CURLOPT_HTTPPOST/CURLOPT_MIMEPOST, + # which is engaged for POST requests. For PUT it falls back to CURLOPT_UPLOAD + # and silently drops form fields, so the request is sent without a + # `Content-Type: multipart/form-data; boundary=...` header or body. + # We send the request as POST so the multipart body is encoded correctly, + # then use CURLOPT_CUSTOMREQUEST (exposed by Ethon as :customrequest) to + # restore PUT as the on-the-wire HTTP verb. + # See: https://github.com/typhoeus/typhoeus/issues/389 + content_type_header = header_params['Content-Type'] || header_params['content-type'] + if http_method == :put && content_type_header.is_a?(String) && + content_type_header.start_with?('multipart/form-data') + req_opts[:method] = :post + req_opts[:customrequest] = 'PUT' + end + Typhoeus::Request.new(url, req_opts) end diff --git a/lib/dropbox-sign/models/account_response.rb b/lib/dropbox-sign/models/account_response.rb index 4e96e47..d9ccec8 100644 --- a/lib/dropbox-sign/models/account_response.rb +++ b/lib/dropbox-sign/models/account_response.rb @@ -60,6 +60,9 @@ class AccountResponse # @return [AccountResponseUsage] attr_accessor :usage + # @return [AccountResponseSettings] + attr_accessor :settings + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -73,7 +76,8 @@ def self.attribute_map :'role_code' => :'role_code', :'team_id' => :'team_id', :'locale' => :'locale', - :'usage' => :'usage' + :'usage' => :'usage', + :'settings' => :'settings' } end @@ -100,7 +104,8 @@ def self.openapi_types :'role_code' => :'String', :'team_id' => :'String', :'locale' => :'String', - :'usage' => :'AccountResponseUsage' + :'usage' => :'AccountResponseUsage', + :'settings' => :'AccountResponseSettings' } end @@ -198,6 +203,10 @@ def initialize(attributes = {}) if attributes.key?(:'usage') self.usage = attributes[:'usage'] end + + if attributes.key?(:'settings') + self.settings = attributes[:'settings'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -228,7 +237,8 @@ def ==(o) role_code == o.role_code && team_id == o.team_id && locale == o.locale && - usage == o.usage + usage == o.usage && + settings == o.settings end # @see the `==` method @@ -240,7 +250,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [account_id, email_address, is_locked, is_paid_hs, is_paid_hf, quotas, callback_url, role_code, team_id, locale, usage].hash + [account_id, email_address, is_locked, is_paid_hs, is_paid_hf, quotas, callback_url, role_code, team_id, locale, usage, settings].hash end # Builds the object from hash diff --git a/lib/dropbox-sign/models/template_edit_response.rb b/lib/dropbox-sign/models/account_response_settings.rb similarity index 78% rename from lib/dropbox-sign/models/template_edit_response.rb rename to lib/dropbox-sign/models/account_response_settings.rb index 9a49967..5710c3a 100644 --- a/lib/dropbox-sign/models/template_edit_response.rb +++ b/lib/dropbox-sign/models/account_response_settings.rb @@ -17,15 +17,26 @@ module Dropbox end module Dropbox::Sign - class TemplateEditResponse - # The id of the Template. - # @return [String] - attr_accessor :template_id + # Subset of configured settings + class AccountResponseSettings + # Returns `true` if _Custom access codes_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + # @return [Boolean] + attr_accessor :signer_access_codes + + # Returns `true` if _Text message_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + # @return [Boolean] + attr_accessor :sms_delivery + + # Returns `true` if _Signer authentication_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + # @return [Boolean] + attr_accessor :sms_authentication # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { - :'template_id' => :'template_id' + :'signer_access_codes' => :'signer_access_codes', + :'sms_delivery' => :'sms_delivery', + :'sms_authentication' => :'sms_authentication' } end @@ -42,7 +53,9 @@ def self.acceptable_attributes # Attribute type mapping. def self.openapi_types { - :'template_id' => :'String' + :'signer_access_codes' => :'Boolean', + :'sms_delivery' => :'Boolean', + :'sms_authentication' => :'Boolean' } end @@ -69,32 +82,40 @@ def self.merged_nullable # Attempt to instantiate and hydrate a new instance of this class # @param [Object] data Data to be converted - # @return [TemplateEditResponse] + # @return [AccountResponseSettings] def self.init(data) ApiClient.default.convert_to_type( data, - "TemplateEditResponse" - ) || TemplateEditResponse.new + "AccountResponseSettings" + ) || AccountResponseSettings.new end # Initializes the object # @param [Hash] attributes Model attributes in the form of hash def initialize(attributes = {}) if (!attributes.is_a?(Hash)) - fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::TemplateEditResponse` initialize method" + fail ArgumentError, "The input argument (attributes) must be a hash in `Dropbox::Sign::AccountResponseSettings` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key acceptable_attribute_map = self.class.acceptable_attribute_map attributes = attributes.each_with_object({}) { |(k, v), h| if (!self.class.merged_attributes.key?(k.to_sym)) - fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::TemplateEditResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect + fail ArgumentError, "`#{k}` is not a valid attribute in `Dropbox::Sign::AccountResponseSettings`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } - if attributes.key?(:'template_id') - self.template_id = attributes[:'template_id'] + if attributes.key?(:'signer_access_codes') + self.signer_access_codes = attributes[:'signer_access_codes'] + end + + if attributes.key?(:'sms_delivery') + self.sms_delivery = attributes[:'sms_delivery'] + end + + if attributes.key?(:'sms_authentication') + self.sms_authentication = attributes[:'sms_authentication'] end end @@ -102,36 +123,23 @@ def initialize(attributes = {}) # @return Array for valid properties with the reasons def list_invalid_properties invalid_properties = Array.new - if @template_id.nil? - invalid_properties.push('invalid value for "template_id", template_id cannot be nil.') - end - invalid_properties end # Check to see if the all the properties in the model are valid # @return true if the model is valid def valid? - return false if @template_id.nil? true end - # Custom attribute writer method with validation - # @param [Object] template_id Value to be assigned - def template_id=(template_id) - if template_id.nil? - fail ArgumentError, 'template_id cannot be nil' - end - - @template_id = template_id - end - # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) return true if self.equal?(o) self.class == o.class && - template_id == o.template_id + signer_access_codes == o.signer_access_codes && + sms_delivery == o.sms_delivery && + sms_authentication == o.sms_authentication end # @see the `==` method @@ -143,7 +151,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [template_id].hash + [signer_access_codes, sms_delivery, sms_authentication].hash end # Builds the object from hash diff --git a/lib/dropbox-sign/models/signature_request_edit_request.rb b/lib/dropbox-sign/models/signature_request_edit_request.rb index 299dc70..68e7c2f 100644 --- a/lib/dropbox-sign/models/signature_request_edit_request.rb +++ b/lib/dropbox-sign/models/signature_request_edit_request.rb @@ -77,7 +77,7 @@ class SignatureRequestEditRequest # @return [Boolean] attr_accessor :hide_text_tags - # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. # @return [Boolean] attr_accessor :is_eid diff --git a/lib/dropbox-sign/models/signature_request_edit_with_template_request.rb b/lib/dropbox-sign/models/signature_request_edit_with_template_request.rb index ea8f2a9..d20fef4 100644 --- a/lib/dropbox-sign/models/signature_request_edit_with_template_request.rb +++ b/lib/dropbox-sign/models/signature_request_edit_with_template_request.rb @@ -51,7 +51,7 @@ class SignatureRequestEditWithTemplateRequest # @return [Array] attr_accessor :file_urls - # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. # @return [Boolean] attr_accessor :is_eid diff --git a/lib/dropbox-sign/models/signature_request_send_request.rb b/lib/dropbox-sign/models/signature_request_send_request.rb index 1bfe729..8dec7e4 100644 --- a/lib/dropbox-sign/models/signature_request_send_request.rb +++ b/lib/dropbox-sign/models/signature_request_send_request.rb @@ -81,7 +81,7 @@ class SignatureRequestSendRequest # @return [Boolean] attr_accessor :is_qualified_signature - # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. # @return [Boolean] attr_accessor :is_eid diff --git a/lib/dropbox-sign/models/signature_request_send_with_template_request.rb b/lib/dropbox-sign/models/signature_request_send_with_template_request.rb index ac26472..cf024ca 100644 --- a/lib/dropbox-sign/models/signature_request_send_with_template_request.rb +++ b/lib/dropbox-sign/models/signature_request_send_with_template_request.rb @@ -55,7 +55,7 @@ class SignatureRequestSendWithTemplateRequest # @return [Boolean] attr_accessor :is_qualified_signature - # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + # Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
**NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. # @return [Boolean] attr_accessor :is_eid diff --git a/lib/dropbox-sign/models/sub_signing_options.rb b/lib/dropbox-sign/models/sub_signing_options.rb index 26a6406..7d0969d 100644 --- a/lib/dropbox-sign/models/sub_signing_options.rb +++ b/lib/dropbox-sign/models/sub_signing_options.rb @@ -17,7 +17,7 @@ module Dropbox end module Dropbox::Sign - # This allows the requester to specify the types allowed for creating a signature. **NOTE:** If `signing_options` are not defined in the request, the allowed types will default to those specified in the account settings. + # This allows the requester to specify the types allowed for creating a signature and specify another signing options. **NOTE:** If `signing_options` are not defined in the request, the allowed types will default to those specified in the account settings. **NOTE:** If `force_advanced_signature_details` is set, allowed types has to be defined too. class SubSigningOptions # The default type shown (limited to the listed types) # @return [String] @@ -39,6 +39,10 @@ class SubSigningOptions # @return [Boolean] attr_accessor :upload + # Turning on advanced signature details for the signature request + # @return [Boolean] + attr_accessor :force_advanced_signature_details + class EnumAttributeValidator attr_reader :datatype attr_reader :allowable_values @@ -68,7 +72,8 @@ def self.attribute_map :'draw' => :'draw', :'phone' => :'phone', :'type' => :'type', - :'upload' => :'upload' + :'upload' => :'upload', + :'force_advanced_signature_details' => :'force_advanced_signature_details' } end @@ -89,7 +94,8 @@ def self.openapi_types :'draw' => :'Boolean', :'phone' => :'Boolean', :'type' => :'Boolean', - :'upload' => :'Boolean' + :'upload' => :'Boolean', + :'force_advanced_signature_details' => :'Boolean' } end @@ -167,6 +173,12 @@ def initialize(attributes = {}) else self.upload = false end + + if attributes.key?(:'force_advanced_signature_details') + self.force_advanced_signature_details = attributes[:'force_advanced_signature_details'] + else + self.force_advanced_signature_details = false + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -208,7 +220,8 @@ def ==(o) draw == o.draw && phone == o.phone && type == o.type && - upload == o.upload + upload == o.upload && + force_advanced_signature_details == o.force_advanced_signature_details end # @see the `==` method @@ -220,7 +233,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [default_type, draw, phone, type, upload].hash + [default_type, draw, phone, type, upload, force_advanced_signature_details].hash end # Builds the object from hash diff --git a/lib/dropbox-sign/version.rb b/lib/dropbox-sign/version.rb index e1b2fd3..872214b 100644 --- a/lib/dropbox-sign/version.rb +++ b/lib/dropbox-sign/version.rb @@ -14,5 +14,5 @@ module Dropbox end module Dropbox::Sign - VERSION = '1.10.0' + VERSION = '1.11.0' end diff --git a/openapi-config.yaml b/openapi-config.yaml index 1176020..94b9709 100644 --- a/openapi-config.yaml +++ b/openapi-config.yaml @@ -9,7 +9,7 @@ additionalProperties: gemName: dropbox-sign gemRequiredRubyVersion: '>= 2.7' moduleName: "Dropbox::Sign" - gemVersion: 1.10.0 + gemVersion: 1.11.0 sortModelPropertiesByRequiredFlag: true legacyDiscriminatorBehavior: true gitUserId: hellosign diff --git a/openapi-sdk.yaml b/openapi-sdk.yaml index c123c2e..ed174d3 100644 --- a/openapi-sdk.yaml +++ b/openapi-sdk.yaml @@ -65,6 +65,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -173,6 +175,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -269,6 +273,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 409_example: $ref: '#/components/examples/Error409Response' 4XX_example: @@ -369,6 +375,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -468,6 +476,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -566,10 +576,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 404_example: - $ref: '#/components/examples/Error404Response' 429_example: $ref: '#/components/examples/Error429Response' + 404_example: + $ref: '#/components/examples/Error404Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -677,10 +687,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -769,6 +779,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -873,6 +885,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -983,6 +997,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1086,6 +1102,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1192,6 +1210,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -1290,12 +1310,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1392,10 +1412,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 404_example: - $ref: '#/components/examples/Error404Response' 429_example: $ref: '#/components/examples/Error429Response' + 404_example: + $ref: '#/components/examples/Error404Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1481,10 +1501,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 404_example: - $ref: '#/components/examples/Error404Response' 429_example: $ref: '#/components/examples/Error429Response' + 404_example: + $ref: '#/components/examples/Error404Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1576,12 +1596,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 410_example: $ref: '#/components/examples/Error410Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1675,6 +1695,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -1858,6 +1880,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -1951,6 +1975,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -2046,6 +2072,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -2135,6 +2163,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -2251,6 +2281,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -2344,6 +2376,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -2450,6 +2484,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -2546,10 +2582,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 404_example: - $ref: '#/components/examples/Error404Response' 429_example: $ref: '#/components/examples/Error429Response' + 404_example: + $ref: '#/components/examples/Error404Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -2643,6 +2679,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: [] @@ -2738,6 +2776,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: [] @@ -2836,6 +2876,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -2935,12 +2977,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3040,6 +3082,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -3143,6 +3187,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -3251,10 +3297,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3354,10 +3400,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3471,12 +3517,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3591,12 +3637,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3708,12 +3754,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3825,12 +3871,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -3943,14 +3989,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 410_example: $ref: '#/components/examples/Error410Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -4051,14 +4097,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 410_example: $ref: '#/components/examples/Error410Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -4166,14 +4212,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 410_example: $ref: '#/components/examples/Error410Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -4271,6 +4317,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 410_example: @@ -4394,6 +4442,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 409_example: $ref: '#/components/examples/Error409Response' 4XX_example: @@ -4493,6 +4543,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -4603,14 +4655,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 410_example: $ref: '#/components/examples/Error410Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -4708,6 +4760,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -4812,10 +4866,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5029,6 +5083,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -5138,6 +5194,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -5236,6 +5294,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5316,6 +5376,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5403,6 +5465,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -5500,6 +5564,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5596,10 +5662,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5695,6 +5761,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5808,10 +5876,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -5910,6 +5978,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -6024,10 +6094,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -6133,6 +6203,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -6188,7 +6260,12 @@ paths: tags: - Template summary: 'Create Template' - description: 'Creates a template that can then be used.' + description: |- + Creates a template that can be used in future signature requests. + + If `client_id` is provided, the template will be created as an embedded template. Embedded templates can be used for embedded signature requests and can be edited later by generating a new `edit_url` with [/embedded/edit_url/{template_id}](/api/reference/operation/embeddedEditUrl/). + + Template creation may complete asynchronously after the initial request is accepted. It is recommended that a callback be implemented to listen for the callback event. A `template_created` event indicates the template is ready to use, while a `template_error` event indicates there was a problem while creating the template. If a callback handler has been configured and the event has not been received within 60 minutes of making the call, check the status of the request in the API dashboard and retry the request if necessary. operationId: templateCreate requestBody: required: true @@ -6240,6 +6317,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -6349,6 +6428,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -6444,6 +6525,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -6558,14 +6641,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 422_example: $ref: '#/components/examples/Error422Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -6665,14 +6748,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 422_example: $ref: '#/components/examples/Error422Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -6779,14 +6862,14 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' 422_example: $ref: '#/components/examples/Error422Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -6883,10 +6966,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 404_example: - $ref: '#/components/examples/Error404Response' 429_example: $ref: '#/components/examples/Error429Response' + 404_example: + $ref: '#/components/examples/Error404Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -7006,10 +7089,10 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' - 409_example: - $ref: '#/components/examples/Error409Response' 429_example: $ref: '#/components/examples/Error429Response' + 409_example: + $ref: '#/components/examples/Error409Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -7115,6 +7198,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 4XX_example: @@ -7237,12 +7322,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -7348,6 +7433,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -7456,6 +7543,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -7563,12 +7652,12 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: $ref: '#/components/examples/Error409Response' - 429_example: - $ref: '#/components/examples/Error429Response' 4XX_example: $ref: '#/components/examples/Error4XXResponse' security: @@ -7677,6 +7766,8 @@ paths: $ref: '#/components/examples/Error402Response' 403_example: $ref: '#/components/examples/Error403Response' + 429_example: + $ref: '#/components/examples/Error429Response' 404_example: $ref: '#/components/examples/Error404Response' 409_example: @@ -8136,6 +8227,7 @@ components: - user_activity - document_status - sms_activity + - fax_usage maxItems: 2 minItems: 1 start_date: @@ -8670,7 +8762,7 @@ components: Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
- **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + **NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. type: boolean default: false message: @@ -8997,7 +9089,7 @@ components: Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
- **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + **NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. type: boolean default: false message: @@ -9165,13 +9257,12 @@ components: type: boolean default: false deprecated: true - x-hideOn: doc is_eid: description: |- Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
- **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + **NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. type: boolean default: false message: @@ -9267,13 +9358,12 @@ components: type: boolean default: false deprecated: true - x-hideOn: doc is_eid: description: |- Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.
- **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. + **NOTE:** You need the eID add-on to use this feature. Please [contact sales](https://sign.dropbox.com/form/contact-sales) for more information. Cannot be used in `test_mode`. Only works on requests with one signer. type: boolean default: false message: @@ -10266,9 +10356,11 @@ components: type: object SubSigningOptions: description: |- - This allows the requester to specify the types allowed for creating a signature. + This allows the requester to specify the types allowed for creating a signature and specify another signing options. **NOTE:** If `signing_options` are not defined in the request, the allowed types will default to those specified in the account settings. + + **NOTE:** If `force_advanced_signature_details` is set, allowed types has to be defined too. required: - default_type properties: @@ -10296,6 +10388,10 @@ components: description: 'Allows uploading the signature' type: boolean default: false + force_advanced_signature_details: + description: 'Turning on advanced signature details for the signature request' + type: boolean + default: false type: object SubWhiteLabelingOptions: description: |- @@ -11590,6 +11686,8 @@ components: nullable: true usage: $ref: '#/components/schemas/AccountResponseUsage' + settings: + $ref: '#/components/schemas/AccountResponseSettings' type: object x-internal-class: true OAuthTokenResponse: @@ -11637,6 +11735,20 @@ components: nullable: true type: object x-internal-class: true + AccountResponseSettings: + description: 'Subset of configured settings' + properties: + signer_access_codes: + description: 'Returns `true` if _Custom access codes_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough).' + type: boolean + sms_delivery: + description: 'Returns `true` if _Text message_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough).' + type: boolean + sms_authentication: + description: 'Returns `true` if _Signer authentication_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough).' + type: boolean + type: object + x-internal-class: true AccountResponseUsage: description: 'Details concerning monthly usage' properties: @@ -11966,6 +12078,7 @@ components: - user_activity - document_status - sms_activity + - fax_usage type: object x-internal-class: true SignatureRequestResponse: @@ -13565,14 +13678,6 @@ components: $ref: '#/components/schemas/WarningResponse' type: object x-internal-class: true - TemplateEditResponse: - required: - - template_id - properties: - template_id: - description: 'The id of the Template.' - type: string - type: object TemplateGetResponse: required: - template diff --git a/templates/api_client_typhoeus_partial.mustache b/templates/api_client_typhoeus_partial.mustache index f55f980..116fd36 100644 --- a/templates/api_client_typhoeus_partial.mustache +++ b/templates/api_client_typhoeus_partial.mustache @@ -87,6 +87,22 @@ end end + # Workaround for the Typhoeus/libcurl multipart PUT bug. + # libcurl only builds a multipart body via CURLOPT_HTTPPOST/CURLOPT_MIMEPOST, + # which is engaged for POST requests. For PUT it falls back to CURLOPT_UPLOAD + # and silently drops form fields, so the request is sent without a + # `Content-Type: multipart/form-data; boundary=...` header or body. + # We send the request as POST so the multipart body is encoded correctly, + # then use CURLOPT_CUSTOMREQUEST (exposed by Ethon as :customrequest) to + # restore PUT as the on-the-wire HTTP verb. + # See: https://github.com/typhoeus/typhoeus/issues/389 + content_type_header = header_params['Content-Type'] || header_params['content-type'] + if http_method == :put && content_type_header.is_a?(String) && + content_type_header.start_with?('multipart/form-data') + req_opts[:method] = :post + req_opts[:customrequest] = 'PUT' + end + Typhoeus::Request.new(url, req_opts) end diff --git a/test_fixtures/SignatureRequestCreateEmbeddedRequest.json b/test_fixtures/SignatureRequestCreateEmbeddedRequest.json index 16e8037..097446a 100644 --- a/test_fixtures/SignatureRequestCreateEmbeddedRequest.json +++ b/test_fixtures/SignatureRequestCreateEmbeddedRequest.json @@ -116,7 +116,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "subject": "The NDA we talked about", "test_mode": true, @@ -252,7 +253,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "subject": "The NDA we talked about", "test_mode": true, diff --git a/test_fixtures/SignatureRequestCreateEmbeddedWithTemplateRequest.json b/test_fixtures/SignatureRequestCreateEmbeddedWithTemplateRequest.json index a9597ea..f997b28 100644 --- a/test_fixtures/SignatureRequestCreateEmbeddedWithTemplateRequest.json +++ b/test_fixtures/SignatureRequestCreateEmbeddedWithTemplateRequest.json @@ -54,7 +54,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "subject": "Purchase Order", "template_ids": [ diff --git a/test_fixtures/SignatureRequestSendRequest.json b/test_fixtures/SignatureRequestSendRequest.json index 98d12db..1f56eb7 100644 --- a/test_fixtures/SignatureRequestSendRequest.json +++ b/test_fixtures/SignatureRequestSendRequest.json @@ -229,7 +229,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "signing_redirect_url": "https://example.com/redirect", "subject": "The NDA we talked about", @@ -468,7 +469,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "signing_redirect_url": "https://example.com/redirect", "subject": "The NDA we talked about", diff --git a/test_fixtures/SignatureRequestSendWithTemplateRequest.json b/test_fixtures/SignatureRequestSendWithTemplateRequest.json index 4d1cc86..df8e207 100644 --- a/test_fixtures/SignatureRequestSendWithTemplateRequest.json +++ b/test_fixtures/SignatureRequestSendWithTemplateRequest.json @@ -42,7 +42,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "signing_redirect_url": "https://example.com/redirect", "subject": "Purchase Order", diff --git a/test_fixtures/TemplateUpdateRequest.json b/test_fixtures/TemplateUpdateRequest.json new file mode 100644 index 0000000..9c9afbf --- /dev/null +++ b/test_fixtures/TemplateUpdateRequest.json @@ -0,0 +1,18 @@ +{ + "default": { + "title": "Test Title", + "subject": "Test Subject", + "message": "Test Message", + "cc_roles": ["one", "two"], + "form_fields": [ + { + "api_id": "uniqueIdHere_1", + "name": "New name 1" + }, + { + "api_id": "uniqueIdHere_2", + "name": "New name 2" + } + ] + } +} \ No newline at end of file diff --git a/test_fixtures/UnclaimedDraftCreateEmbeddedRequest.json b/test_fixtures/UnclaimedDraftCreateEmbeddedRequest.json index e18890b..addbe6a 100644 --- a/test_fixtures/UnclaimedDraftCreateEmbeddedRequest.json +++ b/test_fixtures/UnclaimedDraftCreateEmbeddedRequest.json @@ -127,7 +127,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "signing_redirect_url": "https://example.com/redirect", "show_progress_stepper": true, diff --git a/test_fixtures/UnclaimedDraftCreateEmbeddedWithTemplateRequest.json b/test_fixtures/UnclaimedDraftCreateEmbeddedWithTemplateRequest.json index 7c72649..d4f26cd 100644 --- a/test_fixtures/UnclaimedDraftCreateEmbeddedWithTemplateRequest.json +++ b/test_fixtures/UnclaimedDraftCreateEmbeddedWithTemplateRequest.json @@ -58,7 +58,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "show_progress_stepper": true, "skip_me_now": true, diff --git a/test_fixtures/UnclaimedDraftCreateRequest.json b/test_fixtures/UnclaimedDraftCreateRequest.json index b74d377..a9ab5b5 100644 --- a/test_fixtures/UnclaimedDraftCreateRequest.json +++ b/test_fixtures/UnclaimedDraftCreateRequest.json @@ -114,7 +114,8 @@ "type": true, "upload": true, "phone": false, - "default_type": "draw" + "default_type": "draw", + "force_advanced_signature_details": false }, "signing_redirect_url": "https://example.com/redirect", "subject": "The NDA we talked about",