diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index c869f2b..913f790 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -59,7 +59,7 @@ jobs: run: echo "PACKAGE_VERSION=$(cat VERSION)" >> $GITHUB_ENV - name: Publish Release to Maven Central - run: ./gradlew closeAndReleaseRepository --no-daemon --no-parallel + run: ./gradlew releaseRepository --no-daemon --no-parallel if: "!endsWith(env.PACKAGE_VERSION, '-SNAPSHOT')" env: ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_USERNAME }} diff --git a/README.md b/README.md index 232b76a..16d7605 100644 --- a/README.md +++ b/README.md @@ -55,7 +55,7 @@ Add this dependency to your project's POM: com.dropbox.sign dropbox-sign - 1.10.0 + 1.11.0 compile ``` @@ -71,7 +71,7 @@ Add this dependency to your project's build file: } dependencies { - implementation "com.dropbox.sign:dropbox-sign:1.10.0" + implementation "com.dropbox.sign:dropbox-sign:1.11.0" } ``` @@ -85,7 +85,7 @@ mvn clean package Then manually install the following JARs: -- `target/dropbox-sign-1.10.0.jar` +- `target/dropbox-sign-1.11.0.jar` - `target/lib/*.jar` ## Getting Started @@ -256,6 +256,7 @@ Class | Method | HTTP request | Description - [AccountGetResponse](docs/AccountGetResponse.md) - [AccountResponse](docs/AccountResponse.md) - [AccountResponseQuotas](docs/AccountResponseQuotas.md) + - [AccountResponseSettings](docs/AccountResponseSettings.md) - [AccountResponseUsage](docs/AccountResponseUsage.md) - [AccountUpdateRequest](docs/AccountUpdateRequest.md) - [AccountVerifyRequest](docs/AccountVerifyRequest.md) @@ -399,7 +400,6 @@ Class | Method | HTTP request | Description - [TemplateCreateRequest](docs/TemplateCreateRequest.md) - [TemplateCreateResponse](docs/TemplateCreateResponse.md) - [TemplateCreateResponseTemplate](docs/TemplateCreateResponseTemplate.md) - - [TemplateEditResponse](docs/TemplateEditResponse.md) - [TemplateGetResponse](docs/TemplateGetResponse.md) - [TemplateListResponse](docs/TemplateListResponse.md) - [TemplateRemoveUserRequest](docs/TemplateRemoveUserRequest.md) @@ -477,7 +477,7 @@ apisupport@hellosign.com This Java package 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` - Build package: `org.openapitools.codegen.languages.JavaClientCodegen` 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/build.gradle b/build.gradle index b08b372..47f85f3 100644 --- a/build.gradle +++ b/build.gradle @@ -21,7 +21,7 @@ apply plugin: 'signing' group = 'com.dropbox.sign' archivesBaseName = 'dropbox-sign' -version = '1.10.0' +version = '1.11.0' sourceCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8 diff --git a/build.sbt b/build.sbt index ba710c3..1bc86fa 100644 --- a/build.sbt +++ b/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "com.dropbox.sign", name := "dropbox-sign", - version := "1.10.0", + version := "1.11.0", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), Compile / javacOptions ++= Seq("-Xlint:deprecation"), diff --git a/docs/AccountResponse.md b/docs/AccountResponse.md index 5b73aa0..18ab59f 100644 --- a/docs/AccountResponse.md +++ b/docs/AccountResponse.md @@ -19,6 +19,7 @@ | `teamId` | ```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..cd13907 --- /dev/null +++ b/docs/AccountResponseSettings.md @@ -0,0 +1,16 @@ + + +# AccountResponseSettings + +Subset of configured settings + +## Properties + +| Name | Type | Description | Notes | +|------------ | ------------- | ------------- | -------------| +| `signerAccessCodes` | ```Boolean``` | Returns `true` if _Custom access codes_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). | | +| `smsDelivery` | ```Boolean``` | Returns `true` if _Text message_ is enabled in Admin Console. [Read more](https://developers.hellosign.com/docs/sms-tools/walkthrough). | | +| `smsAuthentication` | ```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/ReportCreateRequest.md b/docs/ReportCreateRequest.md index 7839030..2d4b116 100644 --- a/docs/ReportCreateRequest.md +++ b/docs/ReportCreateRequest.md @@ -21,6 +21,7 @@ | USER_ACTIVITY | "user_activity" | | DOCUMENT_STATUS | "document_status" | | SMS_ACTIVITY | "sms_activity" | +| FAX_USAGE | "fax_usage" | diff --git a/docs/ReportResponse.md b/docs/ReportResponse.md index aa74d68..bfd56ae 100644 --- a/docs/ReportResponse.md +++ b/docs/ReportResponse.md @@ -22,6 +22,7 @@ Contains information about the report request. | USER_ACTIVITY | "user_activity" | | DOCUMENT_STATUS | "document_status" | | SMS_ACTIVITY | "sms_activity" | +| FAX_USAGE | "fax_usage" | diff --git a/docs/SignatureRequestApi.md b/docs/SignatureRequestApi.md index 939b10e..bf16f02 100644 --- a/docs/SignatureRequestApi.md +++ b/docs/SignatureRequestApi.md @@ -459,6 +459,7 @@ public class SignatureRequestCreateEmbeddedExample signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestSigner(); signers1.name("Jack"); @@ -579,6 +580,7 @@ public class SignatureRequestCreateEmbeddedWithTemplateExample signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestTemplateSigner(); signers1.role("Client"); @@ -1874,6 +1876,7 @@ public class SignatureRequestSendExample signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestSigner(); signers1.name("Jack"); @@ -2000,6 +2003,7 @@ public class SignatureRequestSendWithTemplateExample signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestTemplateSigner(); signers1.role("Client"); diff --git a/docs/SignatureRequestEditRequest.md b/docs/SignatureRequestEditRequest.md index 7fa3aca..b4705fe 100644 --- a/docs/SignatureRequestEditRequest.md +++ b/docs/SignatureRequestEditRequest.md @@ -23,7 +23,7 @@ | `formFieldRules` | [```List```](SubFormFieldRule.md) | Conditional Logic rules for fields defined in `form_fields_per_document`. | | | `formFieldsPerDocument` | [```List```](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` | | | `hideTextTags` | ```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. | | -| `isEid` | ```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. | | +| `isEid` | ```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. | | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Map``` | 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. | | | `signingOptions` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestEditWithTemplateRequest.md b/docs/SignatureRequestEditWithTemplateRequest.md index d079524..42095fa 100644 --- a/docs/SignatureRequestEditWithTemplateRequest.md +++ b/docs/SignatureRequestEditWithTemplateRequest.md @@ -16,7 +16,7 @@ | `customFields` | [```List```](SubCustomField.md) | An array defining values and options for custom fields. Required when a custom field exists in the Template. | | | `files` | ```List``` | Use `files[]` to indicate the uploaded file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | | `fileUrls` | ```List``` | 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. | | -| `isEid` | ```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. | | +| `isEid` | ```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. | | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Map``` | 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. | | | `signingOptions` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestSendRequest.md b/docs/SignatureRequestSendRequest.md index 9143039..a34284a 100644 --- a/docs/SignatureRequestSendRequest.md +++ b/docs/SignatureRequestSendRequest.md @@ -24,7 +24,7 @@ | `formFieldsPerDocument` | [```List```](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` | | | `hideTextTags` | ```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. | | | `isQualifiedSignature` | ```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. | | -| `isEid` | ```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. | | +| `isEid` | ```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. | | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Map``` | 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. | | | `signingOptions` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SignatureRequestSendWithTemplateRequest.md b/docs/SignatureRequestSendWithTemplateRequest.md index 7a8d8c8..425ccff 100644 --- a/docs/SignatureRequestSendWithTemplateRequest.md +++ b/docs/SignatureRequestSendWithTemplateRequest.md @@ -17,7 +17,7 @@ | `files` | ```List``` | Use `files[]` to indicate the uploaded file(s) to send for signature.

This endpoint requires either **files** or **file_urls[]**, but not both. | | | `fileUrls` | ```List``` | 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. | | | `isQualifiedSignature` | ```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. | | -| `isEid` | ```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. | | +| `isEid` | ```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. | | | `message` | ```String``` | The custom message in the email that will be sent to the signers. | | | `metadata` | ```Map``` | 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. | | | `signingOptions` | [```SubSigningOptions```](SubSigningOptions.md) | | | diff --git a/docs/SubSigningOptions.md b/docs/SubSigningOptions.md index bca1160..6f419c3 100644 --- a/docs/SubSigningOptions.md +++ b/docs/SubSigningOptions.md @@ -2,10 +2,12 @@ # 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 | @@ -15,6 +17,7 @@ This allows the requester to specify the types allowed for creating a signature. | `phone` | ```Boolean``` | Allows using a smartphone to email the signature | | | `type` | ```Boolean``` | Allows typing the signature | | | `upload` | ```Boolean``` | Allows uploading the signature | | +| `forceAdvancedSignatureDetails` | ```Boolean``` | Turning on advanced signature details for the signature request | | diff --git a/docs/TemplateApi.md b/docs/TemplateApi.md index dd47048..e923386 100644 --- a/docs/TemplateApi.md +++ b/docs/TemplateApi.md @@ -111,7 +111,11 @@ public class TemplateAddUserExample 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. ### Example diff --git a/docs/TemplateEditResponse.md b/docs/TemplateEditResponse.md deleted file mode 100644 index 88d225e..0000000 --- a/docs/TemplateEditResponse.md +++ /dev/null @@ -1,14 +0,0 @@ - - -# TemplateEditResponse - - - -## Properties - -| Name | Type | Description | Notes | -|------------ | ------------- | ------------- | -------------| -| `templateId`*_required_ | ```String``` | The id of the Template. | | - - - diff --git a/examples/SignatureRequestCreateEmbeddedExample.java b/examples/SignatureRequestCreateEmbeddedExample.java index 5193cee..a432c2f 100644 --- a/examples/SignatureRequestCreateEmbeddedExample.java +++ b/examples/SignatureRequestCreateEmbeddedExample.java @@ -29,6 +29,7 @@ public static void main(String[] args) signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestSigner(); signers1.name("Jack"); diff --git a/examples/SignatureRequestCreateEmbeddedWithTemplateExample.java b/examples/SignatureRequestCreateEmbeddedWithTemplateExample.java index 309d422..f94b403 100644 --- a/examples/SignatureRequestCreateEmbeddedWithTemplateExample.java +++ b/examples/SignatureRequestCreateEmbeddedWithTemplateExample.java @@ -29,6 +29,7 @@ public static void main(String[] args) signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestTemplateSigner(); signers1.role("Client"); diff --git a/examples/SignatureRequestSendExample.java b/examples/SignatureRequestSendExample.java index 313b895..7db66e6 100644 --- a/examples/SignatureRequestSendExample.java +++ b/examples/SignatureRequestSendExample.java @@ -32,6 +32,7 @@ public static void main(String[] args) signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestSigner(); signers1.name("Jack"); diff --git a/examples/SignatureRequestSendWithTemplateExample.java b/examples/SignatureRequestSendWithTemplateExample.java index f44a67e..5c6bd8d 100644 --- a/examples/SignatureRequestSendWithTemplateExample.java +++ b/examples/SignatureRequestSendWithTemplateExample.java @@ -29,6 +29,7 @@ public static void main(String[] args) signingOptions.phone(false); signingOptions.type(true); signingOptions.upload(true); + signingOptions.forceAdvancedSignatureDetails(false); var signers1 = new SubSignatureRequestTemplateSigner(); signers1.role("Client"); diff --git a/gradle.properties b/gradle.properties index c73ffdd..1266e5e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,7 +6,7 @@ #target = android GROUP=com.dropbox.sign POM_ARTIFACT_ID=dropbox-sign -VERSION_NAME=1.10.0 +VERSION_NAME=1.11.0 POM_NAME=Dropbox Sign Java SDK POM_DESCRIPTION=Use the Dropbox Sign Java SDK to connect your Java app to the service of Dropbox Sign in microseconds! diff --git a/openapi-config.yaml b/openapi-config.yaml index 50911c2..a50b0be 100644 --- a/openapi-config.yaml +++ b/openapi-config.yaml @@ -16,7 +16,7 @@ additionalProperties: groupId: com.dropbox.sign artifactId: dropbox-sign artifactName: Dropbox Sign Java SDK - artifactVersion: "1.10.0" + artifactVersion: "1.11.0" artifactUrl: https://github.com/hellosign/dropbox-sign-java artifactDescription: Use the Dropbox Sign Java SDK to connect your Java app to the service of Dropbox Sign in microseconds! scmConnection: scm:git:git://github.com/hellosign/dropbox-sign-java.git 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/pom.xml b/pom.xml index f83e5f5..a4ba3e0 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ dropbox-sign jar dropbox-sign - 1.10.0 + 1.11.0 https://github.com/hellosign/dropbox-sign-java Use the Dropbox Sign Java SDK to connect your Java app to the service of Dropbox Sign in microseconds! diff --git a/src/main/java/com/dropbox/sign/ApiClient.java b/src/main/java/com/dropbox/sign/ApiClient.java index d272312..c3e7461 100644 --- a/src/main/java/com/dropbox/sign/ApiClient.java +++ b/src/main/java/com/dropbox/sign/ApiClient.java @@ -147,7 +147,7 @@ public ApiClient(Map authMap) { this.dateFormat = new RFC3339DateFormat(); // Set default User-Agent. - setUserAgent("OpenAPI-Generator/1.10.0/java"); + setUserAgent("OpenAPI-Generator/1.11.0/java"); // Setup authentications (key: authentication name, value: authentication). authentications = new HashMap<>(); diff --git a/src/main/java/com/dropbox/sign/Configuration.java b/src/main/java/com/dropbox/sign/Configuration.java index 8c4ca77..e41abc0 100644 --- a/src/main/java/com/dropbox/sign/Configuration.java +++ b/src/main/java/com/dropbox/sign/Configuration.java @@ -16,7 +16,7 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.12.0") public class Configuration { - public static final String VERSION = "1.10.0"; + public static final String VERSION = "1.11.0"; private static volatile ApiClient defaultApiClient = new ApiClient(); diff --git a/src/main/java/com/dropbox/sign/api/TemplateApi.java b/src/main/java/com/dropbox/sign/api/TemplateApi.java index 14eeae0..f70c013 100644 --- a/src/main/java/com/dropbox/sign/api/TemplateApi.java +++ b/src/main/java/com/dropbox/sign/api/TemplateApi.java @@ -144,7 +144,18 @@ public ApiResponse templateAddUserWithHttpInfo( } /** - * Create Template Creates a template that can then be used. + * Create Template 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 templateCreateRequest (required) * @return TemplateCreateResponse @@ -163,7 +174,18 @@ public TemplateCreateResponse templateCreate(TemplateCreateRequest templateCreat } /** - * Create Template Creates a template that can then be used. + * Create Template 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 templateCreateRequest (required) * @return ApiResponse<TemplateCreateResponse> diff --git a/src/main/java/com/dropbox/sign/model/AccountResponse.java b/src/main/java/com/dropbox/sign/model/AccountResponse.java index 02ee9cf..7d69484 100644 --- a/src/main/java/com/dropbox/sign/model/AccountResponse.java +++ b/src/main/java/com/dropbox/sign/model/AccountResponse.java @@ -35,7 +35,8 @@ AccountResponse.JSON_PROPERTY_ROLE_CODE, AccountResponse.JSON_PROPERTY_TEAM_ID, AccountResponse.JSON_PROPERTY_LOCALE, - AccountResponse.JSON_PROPERTY_USAGE + AccountResponse.JSON_PROPERTY_USAGE, + AccountResponse.JSON_PROPERTY_SETTINGS }) @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", @@ -75,6 +76,9 @@ public class AccountResponse { public static final String JSON_PROPERTY_USAGE = "usage"; @javax.annotation.Nullable private AccountResponseUsage usage; + public static final String JSON_PROPERTY_SETTINGS = "settings"; + @javax.annotation.Nullable private AccountResponseSettings settings; + public AccountResponse() {} /** @@ -335,6 +339,28 @@ public void setUsage(@javax.annotation.Nullable AccountResponseUsage usage) { this.usage = usage; } + public AccountResponse settings(@javax.annotation.Nullable AccountResponseSettings settings) { + this.settings = settings; + return this; + } + + /** + * Get settings + * + * @return settings + */ + @javax.annotation.Nullable @JsonProperty(JSON_PROPERTY_SETTINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public AccountResponseSettings getSettings() { + return settings; + } + + @JsonProperty(JSON_PROPERTY_SETTINGS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setSettings(@javax.annotation.Nullable AccountResponseSettings settings) { + this.settings = settings; + } + /** Return true if this AccountResponse object is equal to o. */ @Override public boolean equals(Object o) { @@ -355,7 +381,8 @@ public boolean equals(Object o) { && Objects.equals(this.roleCode, accountResponse.roleCode) && Objects.equals(this.teamId, accountResponse.teamId) && Objects.equals(this.locale, accountResponse.locale) - && Objects.equals(this.usage, accountResponse.usage); + && Objects.equals(this.usage, accountResponse.usage) + && Objects.equals(this.settings, accountResponse.settings); } @Override @@ -371,7 +398,8 @@ public int hashCode() { roleCode, teamId, locale, - usage); + usage, + settings); } @Override @@ -389,6 +417,7 @@ public String toString() { sb.append(" teamId: ").append(toIndentedString(teamId)).append("\n"); sb.append(" locale: ").append(toIndentedString(locale)).append("\n"); sb.append(" usage: ").append(toIndentedString(usage)).append("\n"); + sb.append(" settings: ").append(toIndentedString(settings)).append("\n"); sb.append("}"); return sb.toString(); } @@ -609,6 +638,24 @@ public Map createFormData() throws ApiException { map.put("usage", JSON.getDefault().getMapper().writeValueAsString(usage)); } } + if (settings != null) { + if (isFileTypeOrListOfFiles(settings)) { + fileTypeFound = true; + } + + if (settings.getClass().equals(java.io.File.class) + || settings.getClass().equals(Integer.class) + || settings.getClass().equals(String.class) + || settings.getClass().isEnum()) { + map.put("settings", settings); + } else if (isListOfFile(settings)) { + for (int i = 0; i < getListSize(settings); i++) { + map.put("settings[" + i + "]", getFromList(settings, i)); + } + } else { + map.put("settings", JSON.getDefault().getMapper().writeValueAsString(settings)); + } + } } catch (Exception e) { throw new ApiException(e); } diff --git a/src/main/java/com/dropbox/sign/model/AccountResponseSettings.java b/src/main/java/com/dropbox/sign/model/AccountResponseSettings.java new file mode 100644 index 0000000..1f43c1d --- /dev/null +++ b/src/main/java/com/dropbox/sign/model/AccountResponseSettings.java @@ -0,0 +1,278 @@ +/* + * Dropbox Sign API + * Dropbox Sign v3 API + * + * The version of the OpenAPI document: 3.0.0 + * Contact: apisupport@hellosign.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package com.dropbox.sign.model; + +import com.dropbox.sign.ApiException; +import com.dropbox.sign.JSON; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import com.fasterxml.jackson.databind.ObjectMapper; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; + +/** Subset of configured settings */ +@JsonPropertyOrder({ + AccountResponseSettings.JSON_PROPERTY_SIGNER_ACCESS_CODES, + AccountResponseSettings.JSON_PROPERTY_SMS_DELIVERY, + AccountResponseSettings.JSON_PROPERTY_SMS_AUTHENTICATION +}) +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.12.0") +@JsonIgnoreProperties(ignoreUnknown = true) +public class AccountResponseSettings { + public static final String JSON_PROPERTY_SIGNER_ACCESS_CODES = "signer_access_codes"; + @javax.annotation.Nullable private Boolean signerAccessCodes; + + public static final String JSON_PROPERTY_SMS_DELIVERY = "sms_delivery"; + @javax.annotation.Nullable private Boolean smsDelivery; + + public static final String JSON_PROPERTY_SMS_AUTHENTICATION = "sms_authentication"; + @javax.annotation.Nullable private Boolean smsAuthentication; + + public AccountResponseSettings() {} + + /** + * Attempt to instantiate and hydrate a new instance of this class + * + * @param jsonData String of JSON data representing target object + */ + public static AccountResponseSettings init(String jsonData) throws Exception { + return new ObjectMapper().readValue(jsonData, AccountResponseSettings.class); + } + + public static AccountResponseSettings init(HashMap data) throws Exception { + return new ObjectMapper() + .readValue( + new ObjectMapper().writeValueAsString(data), AccountResponseSettings.class); + } + + public AccountResponseSettings signerAccessCodes( + @javax.annotation.Nullable Boolean signerAccessCodes) { + this.signerAccessCodes = signerAccessCodes; + return this; + } + + /** + * Returns `true` if _Custom access codes_ is enabled in Admin Console. [Read + * more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + * + * @return signerAccessCodes + */ + @javax.annotation.Nullable @JsonProperty(JSON_PROPERTY_SIGNER_ACCESS_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getSignerAccessCodes() { + return signerAccessCodes; + } + + @JsonProperty(JSON_PROPERTY_SIGNER_ACCESS_CODES) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setSignerAccessCodes(@javax.annotation.Nullable Boolean signerAccessCodes) { + this.signerAccessCodes = signerAccessCodes; + } + + public AccountResponseSettings smsDelivery(@javax.annotation.Nullable Boolean smsDelivery) { + this.smsDelivery = smsDelivery; + return this; + } + + /** + * Returns `true` if _Text message_ is enabled in Admin Console. [Read + * more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + * + * @return smsDelivery + */ + @javax.annotation.Nullable @JsonProperty(JSON_PROPERTY_SMS_DELIVERY) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getSmsDelivery() { + return smsDelivery; + } + + @JsonProperty(JSON_PROPERTY_SMS_DELIVERY) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setSmsDelivery(@javax.annotation.Nullable Boolean smsDelivery) { + this.smsDelivery = smsDelivery; + } + + public AccountResponseSettings smsAuthentication( + @javax.annotation.Nullable Boolean smsAuthentication) { + this.smsAuthentication = smsAuthentication; + return this; + } + + /** + * Returns `true` if _Signer authentication_ is enabled in Admin Console. [Read + * more](https://developers.hellosign.com/docs/sms-tools/walkthrough). + * + * @return smsAuthentication + */ + @javax.annotation.Nullable @JsonProperty(JSON_PROPERTY_SMS_AUTHENTICATION) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getSmsAuthentication() { + return smsAuthentication; + } + + @JsonProperty(JSON_PROPERTY_SMS_AUTHENTICATION) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setSmsAuthentication(@javax.annotation.Nullable Boolean smsAuthentication) { + this.smsAuthentication = smsAuthentication; + } + + /** Return true if this AccountResponseSettings object is equal to o. */ + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AccountResponseSettings accountResponseSettings = (AccountResponseSettings) o; + return Objects.equals(this.signerAccessCodes, accountResponseSettings.signerAccessCodes) + && Objects.equals(this.smsDelivery, accountResponseSettings.smsDelivery) + && Objects.equals( + this.smsAuthentication, accountResponseSettings.smsAuthentication); + } + + @Override + public int hashCode() { + return Objects.hash(signerAccessCodes, smsDelivery, smsAuthentication); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AccountResponseSettings {\n"); + sb.append(" signerAccessCodes: ") + .append(toIndentedString(signerAccessCodes)) + .append("\n"); + sb.append(" smsDelivery: ").append(toIndentedString(smsDelivery)).append("\n"); + sb.append(" smsAuthentication: ") + .append(toIndentedString(smsAuthentication)) + .append("\n"); + sb.append("}"); + return sb.toString(); + } + + public Map createFormData() throws ApiException { + Map map = new HashMap<>(); + boolean fileTypeFound = false; + try { + if (signerAccessCodes != null) { + if (isFileTypeOrListOfFiles(signerAccessCodes)) { + fileTypeFound = true; + } + + if (signerAccessCodes.getClass().equals(java.io.File.class) + || signerAccessCodes.getClass().equals(Integer.class) + || signerAccessCodes.getClass().equals(String.class) + || signerAccessCodes.getClass().isEnum()) { + map.put("signer_access_codes", signerAccessCodes); + } else if (isListOfFile(signerAccessCodes)) { + for (int i = 0; i < getListSize(signerAccessCodes); i++) { + map.put( + "signer_access_codes[" + i + "]", + getFromList(signerAccessCodes, i)); + } + } else { + map.put( + "signer_access_codes", + JSON.getDefault().getMapper().writeValueAsString(signerAccessCodes)); + } + } + if (smsDelivery != null) { + if (isFileTypeOrListOfFiles(smsDelivery)) { + fileTypeFound = true; + } + + if (smsDelivery.getClass().equals(java.io.File.class) + || smsDelivery.getClass().equals(Integer.class) + || smsDelivery.getClass().equals(String.class) + || smsDelivery.getClass().isEnum()) { + map.put("sms_delivery", smsDelivery); + } else if (isListOfFile(smsDelivery)) { + for (int i = 0; i < getListSize(smsDelivery); i++) { + map.put("sms_delivery[" + i + "]", getFromList(smsDelivery, i)); + } + } else { + map.put( + "sms_delivery", + JSON.getDefault().getMapper().writeValueAsString(smsDelivery)); + } + } + if (smsAuthentication != null) { + if (isFileTypeOrListOfFiles(smsAuthentication)) { + fileTypeFound = true; + } + + if (smsAuthentication.getClass().equals(java.io.File.class) + || smsAuthentication.getClass().equals(Integer.class) + || smsAuthentication.getClass().equals(String.class) + || smsAuthentication.getClass().isEnum()) { + map.put("sms_authentication", smsAuthentication); + } else if (isListOfFile(smsAuthentication)) { + for (int i = 0; i < getListSize(smsAuthentication); i++) { + map.put("sms_authentication[" + i + "]", getFromList(smsAuthentication, i)); + } + } else { + map.put( + "sms_authentication", + JSON.getDefault().getMapper().writeValueAsString(smsAuthentication)); + } + } + } catch (Exception e) { + throw new ApiException(e); + } + + return fileTypeFound ? map : new HashMap<>(); + } + + private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { + return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); + } + + private boolean isListOfFile(Object obj) throws Exception { + return obj instanceof java.util.List + && !isListEmpty(obj) + && getFromList(obj, 0) instanceof java.io.File; + } + + private boolean isListEmpty(Object obj) throws Exception { + return (boolean) + Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); + } + + private Object getFromList(Object obj, int index) throws Exception { + return Class.forName(java.util.List.class.getName()) + .getMethod("get", int.class) + .invoke(obj, index); + } + + private int getListSize(Object obj) throws Exception { + return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } +} diff --git a/src/main/java/com/dropbox/sign/model/ReportCreateRequest.java b/src/main/java/com/dropbox/sign/model/ReportCreateRequest.java index 38e625d..3efd6b8 100644 --- a/src/main/java/com/dropbox/sign/model/ReportCreateRequest.java +++ b/src/main/java/com/dropbox/sign/model/ReportCreateRequest.java @@ -47,7 +47,9 @@ public enum ReportTypeEnum { DOCUMENT_STATUS(String.valueOf("document_status")), - SMS_ACTIVITY(String.valueOf("sms_activity")); + SMS_ACTIVITY(String.valueOf("sms_activity")), + + FAX_USAGE(String.valueOf("fax_usage")); private String value; diff --git a/src/main/java/com/dropbox/sign/model/ReportResponse.java b/src/main/java/com/dropbox/sign/model/ReportResponse.java index 6d5079f..b919980 100644 --- a/src/main/java/com/dropbox/sign/model/ReportResponse.java +++ b/src/main/java/com/dropbox/sign/model/ReportResponse.java @@ -54,7 +54,9 @@ public enum ReportTypeEnum { DOCUMENT_STATUS(String.valueOf("document_status")), - SMS_ACTIVITY(String.valueOf("sms_activity")); + SMS_ACTIVITY(String.valueOf("sms_activity")), + + FAX_USAGE(String.valueOf("fax_usage")); private String value; diff --git a/src/main/java/com/dropbox/sign/model/SignatureRequestEditRequest.java b/src/main/java/com/dropbox/sign/model/SignatureRequestEditRequest.java index 0173d32..85a485a 100644 --- a/src/main/java/com/dropbox/sign/model/SignatureRequestEditRequest.java +++ b/src/main/java/com/dropbox/sign/model/SignatureRequestEditRequest.java @@ -631,9 +631,10 @@ public SignatureRequestEditRequest isEid(@javax.annotation.Nullable Boolean isEi /** * 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. + * 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. * * @return isEid */ diff --git a/src/main/java/com/dropbox/sign/model/SignatureRequestEditWithTemplateRequest.java b/src/main/java/com/dropbox/sign/model/SignatureRequestEditWithTemplateRequest.java index c49c66f..21daacc 100644 --- a/src/main/java/com/dropbox/sign/model/SignatureRequestEditWithTemplateRequest.java +++ b/src/main/java/com/dropbox/sign/model/SignatureRequestEditWithTemplateRequest.java @@ -369,9 +369,10 @@ public SignatureRequestEditWithTemplateRequest isEid(@javax.annotation.Nullable /** * 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. + * 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. * * @return isEid */ diff --git a/src/main/java/com/dropbox/sign/model/SignatureRequestSendRequest.java b/src/main/java/com/dropbox/sign/model/SignatureRequestSendRequest.java index 252b391..912bf0f 100644 --- a/src/main/java/com/dropbox/sign/model/SignatureRequestSendRequest.java +++ b/src/main/java/com/dropbox/sign/model/SignatureRequestSendRequest.java @@ -666,9 +666,10 @@ public SignatureRequestSendRequest isEid(@javax.annotation.Nullable Boolean isEi /** * 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. + * 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. * * @return isEid */ diff --git a/src/main/java/com/dropbox/sign/model/SignatureRequestSendWithTemplateRequest.java b/src/main/java/com/dropbox/sign/model/SignatureRequestSendWithTemplateRequest.java index eba4b14..0c0055e 100644 --- a/src/main/java/com/dropbox/sign/model/SignatureRequestSendWithTemplateRequest.java +++ b/src/main/java/com/dropbox/sign/model/SignatureRequestSendWithTemplateRequest.java @@ -404,9 +404,10 @@ public SignatureRequestSendWithTemplateRequest isEid(@javax.annotation.Nullable /** * 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. + * 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. * * @return isEid */ diff --git a/src/main/java/com/dropbox/sign/model/SubSigningOptions.java b/src/main/java/com/dropbox/sign/model/SubSigningOptions.java index 0dea6a6..6b9c493 100644 --- a/src/main/java/com/dropbox/sign/model/SubSigningOptions.java +++ b/src/main/java/com/dropbox/sign/model/SubSigningOptions.java @@ -26,16 +26,18 @@ import java.util.Objects; /** - * 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. */ @JsonPropertyOrder({ SubSigningOptions.JSON_PROPERTY_DEFAULT_TYPE, SubSigningOptions.JSON_PROPERTY_DRAW, SubSigningOptions.JSON_PROPERTY_PHONE, SubSigningOptions.JSON_PROPERTY_TYPE, - SubSigningOptions.JSON_PROPERTY_UPLOAD + SubSigningOptions.JSON_PROPERTY_UPLOAD, + SubSigningOptions.JSON_PROPERTY_FORCE_ADVANCED_SIGNATURE_DETAILS }) @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", @@ -94,6 +96,10 @@ public static DefaultTypeEnum fromValue(String value) { public static final String JSON_PROPERTY_UPLOAD = "upload"; @javax.annotation.Nullable private Boolean upload = false; + public static final String JSON_PROPERTY_FORCE_ADVANCED_SIGNATURE_DETAILS = + "force_advanced_signature_details"; + @javax.annotation.Nullable private Boolean forceAdvancedSignatureDetails = false; + public SubSigningOptions() {} /** @@ -221,6 +227,30 @@ public void setUpload(@javax.annotation.Nullable Boolean upload) { this.upload = upload; } + public SubSigningOptions forceAdvancedSignatureDetails( + @javax.annotation.Nullable Boolean forceAdvancedSignatureDetails) { + this.forceAdvancedSignatureDetails = forceAdvancedSignatureDetails; + return this; + } + + /** + * Turning on advanced signature details for the signature request + * + * @return forceAdvancedSignatureDetails + */ + @javax.annotation.Nullable @JsonProperty(JSON_PROPERTY_FORCE_ADVANCED_SIGNATURE_DETAILS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getForceAdvancedSignatureDetails() { + return forceAdvancedSignatureDetails; + } + + @JsonProperty(JSON_PROPERTY_FORCE_ADVANCED_SIGNATURE_DETAILS) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setForceAdvancedSignatureDetails( + @javax.annotation.Nullable Boolean forceAdvancedSignatureDetails) { + this.forceAdvancedSignatureDetails = forceAdvancedSignatureDetails; + } + /** Return true if this SubSigningOptions object is equal to o. */ @Override public boolean equals(Object o) { @@ -235,12 +265,15 @@ public boolean equals(Object o) { && Objects.equals(this.draw, subSigningOptions.draw) && Objects.equals(this.phone, subSigningOptions.phone) && Objects.equals(this.type, subSigningOptions.type) - && Objects.equals(this.upload, subSigningOptions.upload); + && Objects.equals(this.upload, subSigningOptions.upload) + && Objects.equals( + this.forceAdvancedSignatureDetails, + subSigningOptions.forceAdvancedSignatureDetails); } @Override public int hashCode() { - return Objects.hash(defaultType, draw, phone, type, upload); + return Objects.hash(defaultType, draw, phone, type, upload, forceAdvancedSignatureDetails); } @Override @@ -252,6 +285,9 @@ public String toString() { sb.append(" phone: ").append(toIndentedString(phone)).append("\n"); sb.append(" type: ").append(toIndentedString(type)).append("\n"); sb.append(" upload: ").append(toIndentedString(upload)).append("\n"); + sb.append(" forceAdvancedSignatureDetails: ") + .append(toIndentedString(forceAdvancedSignatureDetails)) + .append("\n"); sb.append("}"); return sb.toString(); } @@ -352,6 +388,30 @@ public Map createFormData() throws ApiException { map.put("upload", JSON.getDefault().getMapper().writeValueAsString(upload)); } } + if (forceAdvancedSignatureDetails != null) { + if (isFileTypeOrListOfFiles(forceAdvancedSignatureDetails)) { + fileTypeFound = true; + } + + if (forceAdvancedSignatureDetails.getClass().equals(java.io.File.class) + || forceAdvancedSignatureDetails.getClass().equals(Integer.class) + || forceAdvancedSignatureDetails.getClass().equals(String.class) + || forceAdvancedSignatureDetails.getClass().isEnum()) { + map.put("force_advanced_signature_details", forceAdvancedSignatureDetails); + } else if (isListOfFile(forceAdvancedSignatureDetails)) { + for (int i = 0; i < getListSize(forceAdvancedSignatureDetails); i++) { + map.put( + "force_advanced_signature_details[" + i + "]", + getFromList(forceAdvancedSignatureDetails, i)); + } + } else { + map.put( + "force_advanced_signature_details", + JSON.getDefault() + .getMapper() + .writeValueAsString(forceAdvancedSignatureDetails)); + } + } } catch (Exception e) { throw new ApiException(e); } diff --git a/src/main/java/com/dropbox/sign/model/TemplateEditResponse.java b/src/main/java/com/dropbox/sign/model/TemplateEditResponse.java deleted file mode 100644 index 095b796..0000000 --- a/src/main/java/com/dropbox/sign/model/TemplateEditResponse.java +++ /dev/null @@ -1,168 +0,0 @@ -/* - * Dropbox Sign API - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -package com.dropbox.sign.model; - -import com.dropbox.sign.ApiException; -import com.dropbox.sign.JSON; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonPropertyOrder; -import com.fasterxml.jackson.databind.ObjectMapper; -import java.util.HashMap; -import java.util.Map; -import java.util.Objects; - -/** TemplateEditResponse */ -@JsonPropertyOrder({TemplateEditResponse.JSON_PROPERTY_TEMPLATE_ID}) -@javax.annotation.Generated( - value = "org.openapitools.codegen.languages.JavaClientCodegen", - comments = "Generator version: 7.12.0") -@JsonIgnoreProperties(ignoreUnknown = true) -public class TemplateEditResponse { - public static final String JSON_PROPERTY_TEMPLATE_ID = "template_id"; - @javax.annotation.Nonnull private String templateId; - - public TemplateEditResponse() {} - - /** - * Attempt to instantiate and hydrate a new instance of this class - * - * @param jsonData String of JSON data representing target object - */ - public static TemplateEditResponse init(String jsonData) throws Exception { - return new ObjectMapper().readValue(jsonData, TemplateEditResponse.class); - } - - public static TemplateEditResponse init(HashMap data) throws Exception { - return new ObjectMapper() - .readValue(new ObjectMapper().writeValueAsString(data), TemplateEditResponse.class); - } - - public TemplateEditResponse templateId(@javax.annotation.Nonnull String templateId) { - this.templateId = templateId; - return this; - } - - /** - * The id of the Template. - * - * @return templateId - */ - @javax.annotation.Nonnull - @JsonProperty(JSON_PROPERTY_TEMPLATE_ID) - @JsonInclude(value = JsonInclude.Include.ALWAYS) - public String getTemplateId() { - return templateId; - } - - @JsonProperty(JSON_PROPERTY_TEMPLATE_ID) - @JsonInclude(value = JsonInclude.Include.ALWAYS) - public void setTemplateId(@javax.annotation.Nonnull String templateId) { - this.templateId = templateId; - } - - /** Return true if this TemplateEditResponse object is equal to o. */ - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - TemplateEditResponse templateEditResponse = (TemplateEditResponse) o; - return Objects.equals(this.templateId, templateEditResponse.templateId); - } - - @Override - public int hashCode() { - return Objects.hash(templateId); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("class TemplateEditResponse {\n"); - sb.append(" templateId: ").append(toIndentedString(templateId)).append("\n"); - sb.append("}"); - return sb.toString(); - } - - public Map createFormData() throws ApiException { - Map map = new HashMap<>(); - boolean fileTypeFound = false; - try { - if (templateId != null) { - if (isFileTypeOrListOfFiles(templateId)) { - fileTypeFound = true; - } - - if (templateId.getClass().equals(java.io.File.class) - || templateId.getClass().equals(Integer.class) - || templateId.getClass().equals(String.class) - || templateId.getClass().isEnum()) { - map.put("template_id", templateId); - } else if (isListOfFile(templateId)) { - for (int i = 0; i < getListSize(templateId); i++) { - map.put("template_id[" + i + "]", getFromList(templateId, i)); - } - } else { - map.put( - "template_id", - JSON.getDefault().getMapper().writeValueAsString(templateId)); - } - } - } catch (Exception e) { - throw new ApiException(e); - } - - return fileTypeFound ? map : new HashMap<>(); - } - - private boolean isFileTypeOrListOfFiles(Object obj) throws Exception { - return obj.getClass().equals(java.io.File.class) || isListOfFile(obj); - } - - private boolean isListOfFile(Object obj) throws Exception { - return obj instanceof java.util.List - && !isListEmpty(obj) - && getFromList(obj, 0) instanceof java.io.File; - } - - private boolean isListEmpty(Object obj) throws Exception { - return (boolean) - Class.forName(java.util.List.class.getName()).getMethod("isEmpty").invoke(obj); - } - - private Object getFromList(Object obj, int index) throws Exception { - return Class.forName(java.util.List.class.getName()) - .getMethod("get", int.class) - .invoke(obj, index); - } - - private int getListSize(Object obj) throws Exception { - return (int) Class.forName(java.util.List.class.getName()).getMethod("size").invoke(obj); - } - - /** - * Convert the given object to string with each line indented by 4 spaces (except the first - * line). - */ - private String toIndentedString(Object o) { - if (o == null) { - return "null"; - } - return o.toString().replace("\n", "\n "); - } -} 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",