From fccffea3ed208dcf7479c88085334f7b6b202f76 Mon Sep 17 00:00:00 2001 From: Ivanah Tannica Desoloc Date: Fri, 26 Oct 2018 09:35:01 -0400 Subject: [PATCH 1/4] Manually added missing mergefieldinfo to AgreementInfo model to allow populating fields using the createAgreement API: https://secure.na2.echosign.com/public/docs/restapi/v6#!/agreements/createAgreement --- .../swagger/client/model/AgreementInfo.java | 34 ++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/src/main/java/io/swagger/client/model/AgreementInfo.java b/src/main/java/io/swagger/client/model/AgreementInfo.java index 08bc96d..cf2f38e 100644 --- a/src/main/java/io/swagger/client/model/AgreementInfo.java +++ b/src/main/java/io/swagger/client/model/AgreementInfo.java @@ -14,6 +14,7 @@ package io.swagger.client.model; import java.util.Objects; + import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; @@ -84,6 +85,9 @@ public class AgreementInfo { @SerializedName("postSignOption") private PostSignOption postSignOption = null; + + @SerializedName("mergeFieldInfo") + private List mergeFieldInfo = null; /** * Optional parameter that sets how often you want to send reminders to the participants. If it is not specified, the default frequency set for the account will be used. Should not be provided in offline agreement creation. @@ -469,6 +473,19 @@ public void setExternalId(ExternalId externalId) { this.externalId = externalId; } + public AgreementInfo mergeFieldInfo(List mergeFieldInfo) { + this.mergeFieldInfo = mergeFieldInfo; + return this; + } + + public AgreementInfo addMergeFieldInfoItem(MergefieldInfo mergeFieldInfoItem) { + if (this.mergeFieldInfo == null) { + this.mergeFieldInfo = new ArrayList(); + } + this.mergeFieldInfo.add(mergeFieldInfoItem); + return this; + } + public AgreementInfo fileInfos(List fileInfos) { this.fileInfos = fileInfos; return this; @@ -494,6 +511,19 @@ public List getFileInfos() { public void setFileInfos(List fileInfos) { this.fileInfos = fileInfos; } + + /** + * A list of one or more files (or references to files) that will be sent out for signature. If more than one file is provided, they will be combined into one PDF before being sent out. Note: Only one of the four parameters in every FileInfo object must be specified + * @return fileInfos + **/ + @ApiModelProperty(value = "A list of one or more files (or references to files) that will be sent out for signature. If more than one file is provided, they will be combined into one PDF before being sent out. Note: Only one of the four parameters in every FileInfo object must be specified") + public List getMergeFieldInfo() { + return mergeFieldInfo; + } + + public void setMergeFieldInfo(List mergeFieldInfo) { + this.mergeFieldInfo = mergeFieldInfo; + } public AgreementInfo firstReminderDelay(Integer firstReminderDelay) { this.firstReminderDelay = firstReminderDelay; @@ -791,6 +821,7 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.expirationTime, agreementInfo.expirationTime) && Objects.equals(this.externalId, agreementInfo.externalId) && Objects.equals(this.fileInfos, agreementInfo.fileInfos) && + Objects.equals(this.mergeFieldInfo, agreementInfo.mergeFieldInfo) && Objects.equals(this.firstReminderDelay, agreementInfo.firstReminderDelay) && Objects.equals(this.id, agreementInfo.id) && Objects.equals(this.locale, agreementInfo.locale) && @@ -810,7 +841,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(ccs, createdDate, deviceInfo, documentVisibilityEnabled, emailOption, expirationTime, externalId, fileInfos, firstReminderDelay, id, locale, message, name, participantSetsInfo, postSignOption, reminderFrequency, securityOption, senderEmail, signatureType, state, status, vaultingInfo, workflowId); + return Objects.hash(ccs, createdDate, deviceInfo, documentVisibilityEnabled, emailOption, expirationTime, externalId, fileInfos, mergeFieldInfo, firstReminderDelay, id, locale, message, name, participantSetsInfo, postSignOption, reminderFrequency, securityOption, senderEmail, signatureType, state, status, vaultingInfo, workflowId); } @@ -827,6 +858,7 @@ public String toString() { sb.append(" expirationTime: ").append(toIndentedString(expirationTime)).append("\n"); sb.append(" externalId: ").append(toIndentedString(externalId)).append("\n"); sb.append(" fileInfos: ").append(toIndentedString(fileInfos)).append("\n"); + sb.append(" mergeFieldInfo: ").append(toIndentedString(mergeFieldInfo)).append("\n"); sb.append(" firstReminderDelay: ").append(toIndentedString(firstReminderDelay)).append("\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" locale: ").append(toIndentedString(locale)).append("\n"); From 1cf10acfe56dd325ccbb76e38213d1917f8e2ad8 Mon Sep 17 00:00:00 2001 From: Ivanah Tannica Desoloc Date: Fri, 26 Oct 2018 09:36:44 -0400 Subject: [PATCH 2/4] Manually added missing mergefieldinfo to AgreementInfo model to allow populating fields using the createAgreement API: https://secure.na2.echosign.com/public/docs/restapi/v6#!/agreements/createAgreement --- src/main/java/io/swagger/client/model/AgreementInfo.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/java/io/swagger/client/model/AgreementInfo.java b/src/main/java/io/swagger/client/model/AgreementInfo.java index cf2f38e..1fde45d 100644 --- a/src/main/java/io/swagger/client/model/AgreementInfo.java +++ b/src/main/java/io/swagger/client/model/AgreementInfo.java @@ -14,7 +14,6 @@ package io.swagger.client.model; import java.util.Objects; - import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; From 734cda520003bbe2fb9c9dbd9b8d180ca12aa157 Mon Sep 17 00:00:00 2001 From: Ivanah Tannica Desoloc Date: Fri, 26 Oct 2018 09:43:53 -0400 Subject: [PATCH 3/4] Fixed ApiPropertyValue for getMergeFieldInfo to match that of the API --- src/main/java/io/swagger/client/model/AgreementInfo.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/io/swagger/client/model/AgreementInfo.java b/src/main/java/io/swagger/client/model/AgreementInfo.java index 1fde45d..8cfc2d1 100644 --- a/src/main/java/io/swagger/client/model/AgreementInfo.java +++ b/src/main/java/io/swagger/client/model/AgreementInfo.java @@ -512,10 +512,10 @@ public void setFileInfos(List fileInfos) { } /** - * A list of one or more files (or references to files) that will be sent out for signature. If more than one file is provided, they will be combined into one PDF before being sent out. Note: Only one of the four parameters in every FileInfo object must be specified - * @return fileInfos + * Optional default values for fields to merge into the document. The values will be presented to the signers for editable fields; for read-only fields the provided values will not be editable during the signing process. Merging data into fields is currently not supported when used with libraryDocumentId or libraryDocumentName. Only file and url are currently supported + * @return mergeFieldInfo **/ - @ApiModelProperty(value = "A list of one or more files (or references to files) that will be sent out for signature. If more than one file is provided, they will be combined into one PDF before being sent out. Note: Only one of the four parameters in every FileInfo object must be specified") + @ApiModelProperty(value = "Optional default values for fields to merge into the document. The values will be presented to the signers for editable fields; for read-only fields the provided values will not be editable during the signing process. Merging data into fields is currently not supported when used with libraryDocumentId or libraryDocumentName. Only file and url are currently supported") public List getMergeFieldInfo() { return mergeFieldInfo; } From 200406f775a00bc4163a5be806b993cccdc7de2b Mon Sep 17 00:00:00 2001 From: Ivanah Tannica Desoloc Date: Fri, 26 Oct 2018 10:01:50 -0400 Subject: [PATCH 4/4] Updated documentation for AgreementInfo model --- docs/AgreementInfo.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/AgreementInfo.md b/docs/AgreementInfo.md index cb78e72..9e5181a 100644 --- a/docs/AgreementInfo.md +++ b/docs/AgreementInfo.md @@ -12,6 +12,7 @@ Name | Type | Description | Notes **expirationTime** | [**Date**](Date.md) | Time after which Agreement expires and needs to be signed before it. Format should be yyyy-MM-dd'T'HH:mm:ssZ. For example, e.g 2016-02-25T18:46:19Z represents UTC time. Should not be provided in offline agreement creation. | [optional] **externalId** | [**ExternalId**](ExternalId.md) | An arbitrary value from your system, which can be specified at sending time and then later returned or queried. Should not be provided in offline agreement creation. | [optional] **fileInfos** | [**List<FileInfo>**](FileInfo.md) | A list of one or more files (or references to files) that will be sent out for signature. If more than one file is provided, they will be combined into one PDF before being sent out. Note: Only one of the four parameters in every FileInfo object must be specified | [optional] +**mergeFieldInfo** | [**List<MergefieldInfo>**](MergefieldInfo.md) | Optional default values for fields to merge into the document. The values will be presented to the signers for editable fields; for read-only fields the provided values will not be editable during the signing process. Merging data into fields is currently not supported when used with libraryDocumentId or libraryDocumentName. Only file and url are currently supported | [optional] **firstReminderDelay** | **Integer** | Integer which specifies the delay in hours before sending the first reminder.<br>This is an optional field. The minimum value allowed is 1 hour and the maximum value can’t be more than the difference of agreement creation and expiry time of the agreement in hours.<br>If this is not specified but the reminder frequency is specified, then the first reminder will be sent based on frequency.<br>i.e. if the reminder is created with frequency specified as daily, the firstReminderDelay will be 24 hours. Should not be provided in offline agreement creation. | [optional] **id** | **String** | The unique identifier of the agreement.If provided in POST, it will simply be ignored | [optional] **locale** | **String** | The locale associated with this agreement - specifies the language for the signing page and emails, for example en_US or fr_FR. If none specified, defaults to the language configured for the agreement sender | [optional]