diff --git a/sdks/dotnet/run-build b/sdks/dotnet/run-build index 06d6bb4c7..8a2332ad6 100755 --- a/sdks/dotnet/run-build +++ b/sdks/dotnet/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/src/Dropbox.Sign/Api/"*.cs +rm -f "${DIR}/src/Dropbox.Sign/Model/"*.cs + docker run --rm \ -v "${DIR}/:/local" \ openapitools/openapi-generator-cli:v7.8.0 generate \ diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs deleted file mode 100644 index bea924860..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxLine.cs +++ /dev/null @@ -1,245 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// FaxLine - /// - [DataContract(Name = "FaxLine")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class FaxLine : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected FaxLine() { } - /// - /// Initializes a new instance of the class. - /// - /// Number. - /// Created at. - /// Updated at. - /// accounts. - public FaxLine(string number = default(string), string createdAt = default(string), string updatedAt = default(string), List accounts = default(List)) - { - - this.Number = number; - this.CreatedAt = createdAt; - this.UpdatedAt = updatedAt; - this.Accounts = accounts; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static FaxLine Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of FaxLine"); - } - - return obj; - } - - /// - /// Number - /// - /// Number - [DataMember(Name = "number", EmitDefaultValue = true)] - public string Number { get; set; } - - /// - /// Created at - /// - /// Created at - [DataMember(Name = "created_at", EmitDefaultValue = true)] - public string CreatedAt { get; set; } - - /// - /// Updated at - /// - /// Updated at - [DataMember(Name = "updated_at", EmitDefaultValue = true)] - public string UpdatedAt { get; set; } - - /// - /// Gets or Sets Accounts - /// - [DataMember(Name = "accounts", EmitDefaultValue = true)] - public List Accounts { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class FaxLine {\n"); - sb.Append(" Number: ").Append(Number).Append("\n"); - sb.Append(" CreatedAt: ").Append(CreatedAt).Append("\n"); - sb.Append(" UpdatedAt: ").Append(UpdatedAt).Append("\n"); - sb.Append(" Accounts: ").Append(Accounts).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as FaxLine); - } - - /// - /// Returns true if FaxLine instances are equal - /// - /// Instance of FaxLine to be compared - /// Boolean - public bool Equals(FaxLine input) - { - if (input == null) - { - return false; - } - return - ( - this.Number == input.Number || - (this.Number != null && - this.Number.Equals(input.Number)) - ) && - ( - this.CreatedAt == input.CreatedAt || - (this.CreatedAt != null && - this.CreatedAt.Equals(input.CreatedAt)) - ) && - ( - this.UpdatedAt == input.UpdatedAt || - (this.UpdatedAt != null && - this.UpdatedAt.Equals(input.UpdatedAt)) - ) && - ( - this.Accounts == input.Accounts || - this.Accounts != null && - input.Accounts != null && - this.Accounts.SequenceEqual(input.Accounts) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Number != null) - { - hashCode = (hashCode * 59) + this.Number.GetHashCode(); - } - if (this.CreatedAt != null) - { - hashCode = (hashCode * 59) + this.CreatedAt.GetHashCode(); - } - if (this.UpdatedAt != null) - { - hashCode = (hashCode * 59) + this.UpdatedAt.GetHashCode(); - } - if (this.Accounts != null) - { - hashCode = (hashCode * 59) + this.Accounts.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "number", - Property = "Number", - Type = "string", - Value = Number, - }); - types.Add(new OpenApiType() - { - Name = "created_at", - Property = "CreatedAt", - Type = "string", - Value = CreatedAt, - }); - types.Add(new OpenApiType() - { - Name = "updated_at", - Property = "UpdatedAt", - Type = "string", - Value = UpdatedAt, - }); - types.Add(new OpenApiType() - { - Name = "accounts", - Property = "Accounts", - Type = "List", - Value = Accounts, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFax.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFax.cs deleted file mode 100644 index abb8cab5f..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFax.cs +++ /dev/null @@ -1,397 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// FaxResponseFax - /// - [DataContract(Name = "FaxResponseFax")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class FaxResponseFax : IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected FaxResponseFax() { } - /// - /// Initializes a new instance of the class. - /// - /// Fax ID. - /// Fax Title. - /// Fax Original Title. - /// Fax Subject. - /// Fax Message. - /// Fax Metadata. - /// Fax Created At Timestamp. - /// Fax Sender Email. - /// Fax Transmissions List. - /// Fax Files URL. - public FaxResponseFax(string faxId = default(string), string title = default(string), string originalTitle = default(string), string subject = default(string), string message = default(string), Object metadata = default(Object), int createdAt = default(int), string from = default(string), List transmissions = default(List), string filesUrl = default(string)) - { - - this.FaxId = faxId; - this.Title = title; - this.OriginalTitle = originalTitle; - this.Subject = subject; - this.Message = message; - this.Metadata = metadata; - this.CreatedAt = createdAt; - this.From = from; - this.Transmissions = transmissions; - this.FilesUrl = filesUrl; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static FaxResponseFax Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of FaxResponseFax"); - } - - return obj; - } - - /// - /// Fax ID - /// - /// Fax ID - [DataMember(Name = "fax_id", EmitDefaultValue = true)] - public string FaxId { get; set; } - - /// - /// Fax Title - /// - /// Fax Title - [DataMember(Name = "title", EmitDefaultValue = true)] - public string Title { get; set; } - - /// - /// Fax Original Title - /// - /// Fax Original Title - [DataMember(Name = "original_title", EmitDefaultValue = true)] - public string OriginalTitle { get; set; } - - /// - /// Fax Subject - /// - /// Fax Subject - [DataMember(Name = "subject", EmitDefaultValue = true)] - public string Subject { get; set; } - - /// - /// Fax Message - /// - /// Fax Message - [DataMember(Name = "message", EmitDefaultValue = true)] - public string Message { get; set; } - - /// - /// Fax Metadata - /// - /// Fax Metadata - [DataMember(Name = "metadata", EmitDefaultValue = true)] - public Object Metadata { get; set; } - - /// - /// Fax Created At Timestamp - /// - /// Fax Created At Timestamp - [DataMember(Name = "created_at", EmitDefaultValue = true)] - public int CreatedAt { get; set; } - - /// - /// Fax Sender Email - /// - /// Fax Sender Email - [DataMember(Name = "from", EmitDefaultValue = true)] - public string From { get; set; } - - /// - /// Fax Transmissions List - /// - /// Fax Transmissions List - [DataMember(Name = "transmissions", EmitDefaultValue = true)] - public List Transmissions { get; set; } - - /// - /// Fax Files URL - /// - /// Fax Files URL - [DataMember(Name = "files_url", EmitDefaultValue = true)] - public string FilesUrl { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class FaxResponseFax {\n"); - sb.Append(" FaxId: ").Append(FaxId).Append("\n"); - sb.Append(" Title: ").Append(Title).Append("\n"); - sb.Append(" OriginalTitle: ").Append(OriginalTitle).Append("\n"); - sb.Append(" Subject: ").Append(Subject).Append("\n"); - sb.Append(" Message: ").Append(Message).Append("\n"); - sb.Append(" Metadata: ").Append(Metadata).Append("\n"); - sb.Append(" CreatedAt: ").Append(CreatedAt).Append("\n"); - sb.Append(" From: ").Append(From).Append("\n"); - sb.Append(" Transmissions: ").Append(Transmissions).Append("\n"); - sb.Append(" FilesUrl: ").Append(FilesUrl).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as FaxResponseFax); - } - - /// - /// Returns true if FaxResponseFax instances are equal - /// - /// Instance of FaxResponseFax to be compared - /// Boolean - public bool Equals(FaxResponseFax input) - { - if (input == null) - { - return false; - } - return - ( - this.FaxId == input.FaxId || - (this.FaxId != null && - this.FaxId.Equals(input.FaxId)) - ) && - ( - this.Title == input.Title || - (this.Title != null && - this.Title.Equals(input.Title)) - ) && - ( - this.OriginalTitle == input.OriginalTitle || - (this.OriginalTitle != null && - this.OriginalTitle.Equals(input.OriginalTitle)) - ) && - ( - this.Subject == input.Subject || - (this.Subject != null && - this.Subject.Equals(input.Subject)) - ) && - ( - this.Message == input.Message || - (this.Message != null && - this.Message.Equals(input.Message)) - ) && - ( - this.Metadata == input.Metadata || - (this.Metadata != null && - this.Metadata.Equals(input.Metadata)) - ) && - ( - this.CreatedAt == input.CreatedAt || - this.CreatedAt.Equals(input.CreatedAt) - ) && - ( - this.From == input.From || - (this.From != null && - this.From.Equals(input.From)) - ) && - ( - this.Transmissions == input.Transmissions || - this.Transmissions != null && - input.Transmissions != null && - this.Transmissions.SequenceEqual(input.Transmissions) - ) && - ( - this.FilesUrl == input.FilesUrl || - (this.FilesUrl != null && - this.FilesUrl.Equals(input.FilesUrl)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.FaxId != null) - { - hashCode = (hashCode * 59) + this.FaxId.GetHashCode(); - } - if (this.Title != null) - { - hashCode = (hashCode * 59) + this.Title.GetHashCode(); - } - if (this.OriginalTitle != null) - { - hashCode = (hashCode * 59) + this.OriginalTitle.GetHashCode(); - } - if (this.Subject != null) - { - hashCode = (hashCode * 59) + this.Subject.GetHashCode(); - } - if (this.Message != null) - { - hashCode = (hashCode * 59) + this.Message.GetHashCode(); - } - if (this.Metadata != null) - { - hashCode = (hashCode * 59) + this.Metadata.GetHashCode(); - } - hashCode = (hashCode * 59) + this.CreatedAt.GetHashCode(); - if (this.From != null) - { - hashCode = (hashCode * 59) + this.From.GetHashCode(); - } - if (this.Transmissions != null) - { - hashCode = (hashCode * 59) + this.Transmissions.GetHashCode(); - } - if (this.FilesUrl != null) - { - hashCode = (hashCode * 59) + this.FilesUrl.GetHashCode(); - } - return hashCode; - } - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - IEnumerable IValidatableObject.Validate(ValidationContext validationContext) - { - yield break; - } - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "fax_id", - Property = "FaxId", - Type = "string", - Value = FaxId, - }); - types.Add(new OpenApiType() - { - Name = "title", - Property = "Title", - Type = "string", - Value = Title, - }); - types.Add(new OpenApiType() - { - Name = "original_title", - Property = "OriginalTitle", - Type = "string", - Value = OriginalTitle, - }); - types.Add(new OpenApiType() - { - Name = "subject", - Property = "Subject", - Type = "string", - Value = Subject, - }); - types.Add(new OpenApiType() - { - Name = "message", - Property = "Message", - Type = "string", - Value = Message, - }); - types.Add(new OpenApiType() - { - Name = "metadata", - Property = "Metadata", - Type = "Object", - Value = Metadata, - }); - types.Add(new OpenApiType() - { - Name = "created_at", - Property = "CreatedAt", - Type = "int", - Value = CreatedAt, - }); - types.Add(new OpenApiType() - { - Name = "from", - Property = "From", - Type = "string", - Value = From, - }); - types.Add(new OpenApiType() - { - Name = "transmissions", - Property = "Transmissions", - Type = "List", - Value = Transmissions, - }); - types.Add(new OpenApiType() - { - Name = "files_url", - Property = "FilesUrl", - Type = "string", - Value = FilesUrl, - }); - - return types; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFaxTransmission.cs b/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFaxTransmission.cs deleted file mode 100644 index 51e666148..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/FaxResponseFaxTransmission.cs +++ /dev/null @@ -1,240 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// FaxResponseFaxTransmission - /// - [DataContract(Name = "FaxResponseFaxTransmission")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class FaxResponseFaxTransmission : IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected FaxResponseFaxTransmission() { } - /// - /// Initializes a new instance of the class. - /// - /// Fax Transmission Recipient. - /// Fax Transmission Sender. - /// Fax Transmission Status Code. - /// Fax Transmission Sent Timestamp. - public FaxResponseFaxTransmission(string recipient = default(string), string sender = default(string), string statusCode = default(string), int sentAt = default(int)) - { - - this.Recipient = recipient; - this.Sender = sender; - this.StatusCode = statusCode; - this.SentAt = sentAt; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static FaxResponseFaxTransmission Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of FaxResponseFaxTransmission"); - } - - return obj; - } - - /// - /// Fax Transmission Recipient - /// - /// Fax Transmission Recipient - [DataMember(Name = "recipient", EmitDefaultValue = true)] - public string Recipient { get; set; } - - /// - /// Fax Transmission Sender - /// - /// Fax Transmission Sender - [DataMember(Name = "sender", EmitDefaultValue = true)] - public string Sender { get; set; } - - /// - /// Fax Transmission Status Code - /// - /// Fax Transmission Status Code - [DataMember(Name = "status_code", EmitDefaultValue = true)] - public string StatusCode { get; set; } - - /// - /// Fax Transmission Sent Timestamp - /// - /// Fax Transmission Sent Timestamp - [DataMember(Name = "sent_at", EmitDefaultValue = true)] - public int SentAt { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class FaxResponseFaxTransmission {\n"); - sb.Append(" Recipient: ").Append(Recipient).Append("\n"); - sb.Append(" Sender: ").Append(Sender).Append("\n"); - sb.Append(" StatusCode: ").Append(StatusCode).Append("\n"); - sb.Append(" SentAt: ").Append(SentAt).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as FaxResponseFaxTransmission); - } - - /// - /// Returns true if FaxResponseFaxTransmission instances are equal - /// - /// Instance of FaxResponseFaxTransmission to be compared - /// Boolean - public bool Equals(FaxResponseFaxTransmission input) - { - if (input == null) - { - return false; - } - return - ( - this.Recipient == input.Recipient || - (this.Recipient != null && - this.Recipient.Equals(input.Recipient)) - ) && - ( - this.Sender == input.Sender || - (this.Sender != null && - this.Sender.Equals(input.Sender)) - ) && - ( - this.StatusCode == input.StatusCode || - (this.StatusCode != null && - this.StatusCode.Equals(input.StatusCode)) - ) && - ( - this.SentAt == input.SentAt || - this.SentAt.Equals(input.SentAt) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Recipient != null) - { - hashCode = (hashCode * 59) + this.Recipient.GetHashCode(); - } - if (this.Sender != null) - { - hashCode = (hashCode * 59) + this.Sender.GetHashCode(); - } - if (this.StatusCode != null) - { - hashCode = (hashCode * 59) + this.StatusCode.GetHashCode(); - } - hashCode = (hashCode * 59) + this.SentAt.GetHashCode(); - return hashCode; - } - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - IEnumerable IValidatableObject.Validate(ValidationContext validationContext) - { - yield break; - } - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "recipient", - Property = "Recipient", - Type = "string", - Value = Recipient, - }); - types.Add(new OpenApiType() - { - Name = "sender", - Property = "Sender", - Type = "string", - Value = Sender, - }); - types.Add(new OpenApiType() - { - Name = "status_code", - Property = "StatusCode", - Type = "string", - Value = StatusCode, - }); - types.Add(new OpenApiType() - { - Name = "sent_at", - Property = "SentAt", - Type = "int", - Value = SentAt, - }); - - return types; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedRequest.cs deleted file mode 100644 index ce078442e..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedRequest.cs +++ /dev/null @@ -1,773 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// SignatureRequestEditEmbeddedRequest - /// - [DataContract(Name = "SignatureRequestEditEmbeddedRequest")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class SignatureRequestEditEmbeddedRequest : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected SignatureRequestEditEmbeddedRequest() { } - /// - /// Initializes a new instance of the class. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both.. - /// 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.. - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both.. - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both.. - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. (default to false). - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan. (default to false). - /// A list describing the attachments. - /// The email addresses that should be CCed.. - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. (required). - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template.. - /// fieldOptions. - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`.. - /// Conditional Logic rules for fields defined in `form_fields_per_document`.. - /// 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`. - /// Enables automatic Text Tag removal when set to true. **NOTE:** Removing text tags this way can cause unwanted clipping. We recommend leaving this setting on `false` and instead hiding your text tags using white text or a similar approach. See the [Text Tags Walkthrough](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) for more information. (default to false). - /// The custom message in the email that will be sent to the signers.. - /// 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. - /// The subject in the email that will be sent to the signers.. - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. (default to false). - /// The title you want to assign to the SignatureRequest.. - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. (default to false). - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. (default to false). - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details.. - public SignatureRequestEditEmbeddedRequest(List files = default(List), List fileUrls = default(List), List signers = default(List), List groupedSigners = default(List), bool allowDecline = false, bool allowReassign = false, List attachments = default(List), List ccEmailAddresses = default(List), string clientId = default(string), List customFields = default(List), SubFieldOptions fieldOptions = default(SubFieldOptions), List formFieldGroups = default(List), List formFieldRules = default(List), List formFieldsPerDocument = default(List), bool hideTextTags = false, string message = default(string), Dictionary metadata = default(Dictionary), SubSigningOptions signingOptions = default(SubSigningOptions), string subject = default(string), bool testMode = false, string title = default(string), bool useTextTags = false, bool populateAutoFillFields = false, int? expiresAt = default(int?)) - { - - // to ensure "clientId" is required (not null) - if (clientId == null) - { - throw new ArgumentNullException("clientId is a required property for SignatureRequestEditEmbeddedRequest and cannot be null"); - } - this.ClientId = clientId; - this.Files = files; - this.FileUrls = fileUrls; - this.Signers = signers; - this.GroupedSigners = groupedSigners; - this.AllowDecline = allowDecline; - this.AllowReassign = allowReassign; - this.Attachments = attachments; - this.CcEmailAddresses = ccEmailAddresses; - this.CustomFields = customFields; - this.FieldOptions = fieldOptions; - this.FormFieldGroups = formFieldGroups; - this.FormFieldRules = formFieldRules; - this.FormFieldsPerDocument = formFieldsPerDocument; - this.HideTextTags = hideTextTags; - this.Message = message; - this.Metadata = metadata; - this.SigningOptions = signingOptions; - this.Subject = subject; - this.TestMode = testMode; - this.Title = title; - this.UseTextTags = useTextTags; - this.PopulateAutoFillFields = populateAutoFillFields; - this.ExpiresAt = expiresAt; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static SignatureRequestEditEmbeddedRequest Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of SignatureRequestEditEmbeddedRequest"); - } - - return obj; - } - - /// - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. - /// - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. - [DataMember(Name = "client_id", IsRequired = true, EmitDefaultValue = true)] - public string ClientId { get; set; } - - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - [DataMember(Name = "files", EmitDefaultValue = true)] - public List Files { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "file_urls", EmitDefaultValue = true)] - public List FileUrls { get; set; } - - /// - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - /// - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - [DataMember(Name = "signers", EmitDefaultValue = true)] - public List Signers { get; set; } - - /// - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - /// - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - [DataMember(Name = "grouped_signers", EmitDefaultValue = true)] - public List GroupedSigners { get; set; } - - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - [DataMember(Name = "allow_decline", EmitDefaultValue = true)] - public bool AllowDecline { get; set; } - - /// - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan. - /// - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan. - [DataMember(Name = "allow_reassign", EmitDefaultValue = true)] - public bool AllowReassign { get; set; } - - /// - /// A list describing the attachments - /// - /// A list describing the attachments - [DataMember(Name = "attachments", EmitDefaultValue = true)] - public List Attachments { get; set; } - - /// - /// The email addresses that should be CCed. - /// - /// The email addresses that should be CCed. - [DataMember(Name = "cc_email_addresses", EmitDefaultValue = true)] - public List CcEmailAddresses { get; set; } - - /// - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template. - /// - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template. - [DataMember(Name = "custom_fields", EmitDefaultValue = true)] - public List CustomFields { get; set; } - - /// - /// Gets or Sets FieldOptions - /// - [DataMember(Name = "field_options", EmitDefaultValue = true)] - public SubFieldOptions FieldOptions { get; set; } - - /// - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`. - /// - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`. - [DataMember(Name = "form_field_groups", EmitDefaultValue = true)] - public List FormFieldGroups { get; set; } - - /// - /// Conditional Logic rules for fields defined in `form_fields_per_document`. - /// - /// Conditional Logic rules for fields defined in `form_fields_per_document`. - [DataMember(Name = "form_field_rules", EmitDefaultValue = true)] - public List FormFieldRules { get; set; } - - /// - /// 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` - /// - /// 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` - [DataMember(Name = "form_fields_per_document", EmitDefaultValue = true)] - public List FormFieldsPerDocument { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "hide_text_tags", EmitDefaultValue = true)] - public bool HideTextTags { get; set; } - - /// - /// The custom message in the email that will be sent to the signers. - /// - /// The custom message in the email that will be sent to the signers. - [DataMember(Name = "message", EmitDefaultValue = true)] - public string Message { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "metadata", EmitDefaultValue = true)] - public Dictionary Metadata { get; set; } - - /// - /// Gets or Sets SigningOptions - /// - [DataMember(Name = "signing_options", EmitDefaultValue = true)] - public SubSigningOptions SigningOptions { get; set; } - - /// - /// The subject in the email that will be sent to the signers. - /// - /// The subject in the email that will be sent to the signers. - [DataMember(Name = "subject", EmitDefaultValue = true)] - public string Subject { get; set; } - - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - [DataMember(Name = "test_mode", EmitDefaultValue = true)] - public bool TestMode { get; set; } - - /// - /// The title you want to assign to the SignatureRequest. - /// - /// The title you want to assign to the SignatureRequest. - [DataMember(Name = "title", EmitDefaultValue = true)] - public string Title { get; set; } - - /// - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. - /// - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. - [DataMember(Name = "use_text_tags", EmitDefaultValue = true)] - public bool UseTextTags { get; set; } - - /// - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. - /// - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. - [DataMember(Name = "populate_auto_fill_fields", EmitDefaultValue = true)] - public bool PopulateAutoFillFields { get; set; } - - /// - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details. - /// - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details. - [DataMember(Name = "expires_at", EmitDefaultValue = true)] - public int? ExpiresAt { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class SignatureRequestEditEmbeddedRequest {\n"); - sb.Append(" ClientId: ").Append(ClientId).Append("\n"); - sb.Append(" Files: ").Append(Files).Append("\n"); - sb.Append(" FileUrls: ").Append(FileUrls).Append("\n"); - sb.Append(" Signers: ").Append(Signers).Append("\n"); - sb.Append(" GroupedSigners: ").Append(GroupedSigners).Append("\n"); - sb.Append(" AllowDecline: ").Append(AllowDecline).Append("\n"); - sb.Append(" AllowReassign: ").Append(AllowReassign).Append("\n"); - sb.Append(" Attachments: ").Append(Attachments).Append("\n"); - sb.Append(" CcEmailAddresses: ").Append(CcEmailAddresses).Append("\n"); - sb.Append(" CustomFields: ").Append(CustomFields).Append("\n"); - sb.Append(" FieldOptions: ").Append(FieldOptions).Append("\n"); - sb.Append(" FormFieldGroups: ").Append(FormFieldGroups).Append("\n"); - sb.Append(" FormFieldRules: ").Append(FormFieldRules).Append("\n"); - sb.Append(" FormFieldsPerDocument: ").Append(FormFieldsPerDocument).Append("\n"); - sb.Append(" HideTextTags: ").Append(HideTextTags).Append("\n"); - sb.Append(" Message: ").Append(Message).Append("\n"); - sb.Append(" Metadata: ").Append(Metadata).Append("\n"); - sb.Append(" SigningOptions: ").Append(SigningOptions).Append("\n"); - sb.Append(" Subject: ").Append(Subject).Append("\n"); - sb.Append(" TestMode: ").Append(TestMode).Append("\n"); - sb.Append(" Title: ").Append(Title).Append("\n"); - sb.Append(" UseTextTags: ").Append(UseTextTags).Append("\n"); - sb.Append(" PopulateAutoFillFields: ").Append(PopulateAutoFillFields).Append("\n"); - sb.Append(" ExpiresAt: ").Append(ExpiresAt).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as SignatureRequestEditEmbeddedRequest); - } - - /// - /// Returns true if SignatureRequestEditEmbeddedRequest instances are equal - /// - /// Instance of SignatureRequestEditEmbeddedRequest to be compared - /// Boolean - public bool Equals(SignatureRequestEditEmbeddedRequest input) - { - if (input == null) - { - return false; - } - return - ( - this.ClientId == input.ClientId || - (this.ClientId != null && - this.ClientId.Equals(input.ClientId)) - ) && - ( - this.Files == input.Files || - this.Files != null && - input.Files != null && - this.Files.SequenceEqual(input.Files) - ) && - ( - this.FileUrls == input.FileUrls || - this.FileUrls != null && - input.FileUrls != null && - this.FileUrls.SequenceEqual(input.FileUrls) - ) && - ( - this.Signers == input.Signers || - this.Signers != null && - input.Signers != null && - this.Signers.SequenceEqual(input.Signers) - ) && - ( - this.GroupedSigners == input.GroupedSigners || - this.GroupedSigners != null && - input.GroupedSigners != null && - this.GroupedSigners.SequenceEqual(input.GroupedSigners) - ) && - ( - this.AllowDecline == input.AllowDecline || - this.AllowDecline.Equals(input.AllowDecline) - ) && - ( - this.AllowReassign == input.AllowReassign || - this.AllowReassign.Equals(input.AllowReassign) - ) && - ( - this.Attachments == input.Attachments || - this.Attachments != null && - input.Attachments != null && - this.Attachments.SequenceEqual(input.Attachments) - ) && - ( - this.CcEmailAddresses == input.CcEmailAddresses || - this.CcEmailAddresses != null && - input.CcEmailAddresses != null && - this.CcEmailAddresses.SequenceEqual(input.CcEmailAddresses) - ) && - ( - this.CustomFields == input.CustomFields || - this.CustomFields != null && - input.CustomFields != null && - this.CustomFields.SequenceEqual(input.CustomFields) - ) && - ( - this.FieldOptions == input.FieldOptions || - (this.FieldOptions != null && - this.FieldOptions.Equals(input.FieldOptions)) - ) && - ( - this.FormFieldGroups == input.FormFieldGroups || - this.FormFieldGroups != null && - input.FormFieldGroups != null && - this.FormFieldGroups.SequenceEqual(input.FormFieldGroups) - ) && - ( - this.FormFieldRules == input.FormFieldRules || - this.FormFieldRules != null && - input.FormFieldRules != null && - this.FormFieldRules.SequenceEqual(input.FormFieldRules) - ) && - ( - this.FormFieldsPerDocument == input.FormFieldsPerDocument || - this.FormFieldsPerDocument != null && - input.FormFieldsPerDocument != null && - this.FormFieldsPerDocument.SequenceEqual(input.FormFieldsPerDocument) - ) && - ( - this.HideTextTags == input.HideTextTags || - this.HideTextTags.Equals(input.HideTextTags) - ) && - ( - this.Message == input.Message || - (this.Message != null && - this.Message.Equals(input.Message)) - ) && - ( - this.Metadata == input.Metadata || - this.Metadata != null && - input.Metadata != null && - this.Metadata.SequenceEqual(input.Metadata) - ) && - ( - this.SigningOptions == input.SigningOptions || - (this.SigningOptions != null && - this.SigningOptions.Equals(input.SigningOptions)) - ) && - ( - this.Subject == input.Subject || - (this.Subject != null && - this.Subject.Equals(input.Subject)) - ) && - ( - this.TestMode == input.TestMode || - this.TestMode.Equals(input.TestMode) - ) && - ( - this.Title == input.Title || - (this.Title != null && - this.Title.Equals(input.Title)) - ) && - ( - this.UseTextTags == input.UseTextTags || - this.UseTextTags.Equals(input.UseTextTags) - ) && - ( - this.PopulateAutoFillFields == input.PopulateAutoFillFields || - this.PopulateAutoFillFields.Equals(input.PopulateAutoFillFields) - ) && - ( - this.ExpiresAt == input.ExpiresAt || - (this.ExpiresAt != null && - this.ExpiresAt.Equals(input.ExpiresAt)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.ClientId != null) - { - hashCode = (hashCode * 59) + this.ClientId.GetHashCode(); - } - if (this.Files != null) - { - hashCode = (hashCode * 59) + this.Files.GetHashCode(); - } - if (this.FileUrls != null) - { - hashCode = (hashCode * 59) + this.FileUrls.GetHashCode(); - } - if (this.Signers != null) - { - hashCode = (hashCode * 59) + this.Signers.GetHashCode(); - } - if (this.GroupedSigners != null) - { - hashCode = (hashCode * 59) + this.GroupedSigners.GetHashCode(); - } - hashCode = (hashCode * 59) + this.AllowDecline.GetHashCode(); - hashCode = (hashCode * 59) + this.AllowReassign.GetHashCode(); - if (this.Attachments != null) - { - hashCode = (hashCode * 59) + this.Attachments.GetHashCode(); - } - if (this.CcEmailAddresses != null) - { - hashCode = (hashCode * 59) + this.CcEmailAddresses.GetHashCode(); - } - if (this.CustomFields != null) - { - hashCode = (hashCode * 59) + this.CustomFields.GetHashCode(); - } - if (this.FieldOptions != null) - { - hashCode = (hashCode * 59) + this.FieldOptions.GetHashCode(); - } - if (this.FormFieldGroups != null) - { - hashCode = (hashCode * 59) + this.FormFieldGroups.GetHashCode(); - } - if (this.FormFieldRules != null) - { - hashCode = (hashCode * 59) + this.FormFieldRules.GetHashCode(); - } - if (this.FormFieldsPerDocument != null) - { - hashCode = (hashCode * 59) + this.FormFieldsPerDocument.GetHashCode(); - } - hashCode = (hashCode * 59) + this.HideTextTags.GetHashCode(); - if (this.Message != null) - { - hashCode = (hashCode * 59) + this.Message.GetHashCode(); - } - if (this.Metadata != null) - { - hashCode = (hashCode * 59) + this.Metadata.GetHashCode(); - } - if (this.SigningOptions != null) - { - hashCode = (hashCode * 59) + this.SigningOptions.GetHashCode(); - } - if (this.Subject != null) - { - hashCode = (hashCode * 59) + this.Subject.GetHashCode(); - } - hashCode = (hashCode * 59) + this.TestMode.GetHashCode(); - if (this.Title != null) - { - hashCode = (hashCode * 59) + this.Title.GetHashCode(); - } - hashCode = (hashCode * 59) + this.UseTextTags.GetHashCode(); - hashCode = (hashCode * 59) + this.PopulateAutoFillFields.GetHashCode(); - if (this.ExpiresAt != null) - { - hashCode = (hashCode * 59) + this.ExpiresAt.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "client_id", - Property = "ClientId", - Type = "string", - Value = ClientId, - }); - types.Add(new OpenApiType() - { - Name = "files", - Property = "Files", - Type = "List", - Value = Files, - }); - types.Add(new OpenApiType() - { - Name = "file_urls", - Property = "FileUrls", - Type = "List", - Value = FileUrls, - }); - types.Add(new OpenApiType() - { - Name = "signers", - Property = "Signers", - Type = "List", - Value = Signers, - }); - types.Add(new OpenApiType() - { - Name = "grouped_signers", - Property = "GroupedSigners", - Type = "List", - Value = GroupedSigners, - }); - types.Add(new OpenApiType() - { - Name = "allow_decline", - Property = "AllowDecline", - Type = "bool", - Value = AllowDecline, - }); - types.Add(new OpenApiType() - { - Name = "allow_reassign", - Property = "AllowReassign", - Type = "bool", - Value = AllowReassign, - }); - types.Add(new OpenApiType() - { - Name = "attachments", - Property = "Attachments", - Type = "List", - Value = Attachments, - }); - types.Add(new OpenApiType() - { - Name = "cc_email_addresses", - Property = "CcEmailAddresses", - Type = "List", - Value = CcEmailAddresses, - }); - types.Add(new OpenApiType() - { - Name = "custom_fields", - Property = "CustomFields", - Type = "List", - Value = CustomFields, - }); - types.Add(new OpenApiType() - { - Name = "field_options", - Property = "FieldOptions", - Type = "SubFieldOptions", - Value = FieldOptions, - }); - types.Add(new OpenApiType() - { - Name = "form_field_groups", - Property = "FormFieldGroups", - Type = "List", - Value = FormFieldGroups, - }); - types.Add(new OpenApiType() - { - Name = "form_field_rules", - Property = "FormFieldRules", - Type = "List", - Value = FormFieldRules, - }); - types.Add(new OpenApiType() - { - Name = "form_fields_per_document", - Property = "FormFieldsPerDocument", - Type = "List", - Value = FormFieldsPerDocument, - }); - types.Add(new OpenApiType() - { - Name = "hide_text_tags", - Property = "HideTextTags", - Type = "bool", - Value = HideTextTags, - }); - types.Add(new OpenApiType() - { - Name = "message", - Property = "Message", - Type = "string", - Value = Message, - }); - types.Add(new OpenApiType() - { - Name = "metadata", - Property = "Metadata", - Type = "Dictionary", - Value = Metadata, - }); - types.Add(new OpenApiType() - { - Name = "signing_options", - Property = "SigningOptions", - Type = "SubSigningOptions", - Value = SigningOptions, - }); - types.Add(new OpenApiType() - { - Name = "subject", - Property = "Subject", - Type = "string", - Value = Subject, - }); - types.Add(new OpenApiType() - { - Name = "test_mode", - Property = "TestMode", - Type = "bool", - Value = TestMode, - }); - types.Add(new OpenApiType() - { - Name = "title", - Property = "Title", - Type = "string", - Value = Title, - }); - types.Add(new OpenApiType() - { - Name = "use_text_tags", - Property = "UseTextTags", - Type = "bool", - Value = UseTextTags, - }); - types.Add(new OpenApiType() - { - Name = "populate_auto_fill_fields", - Property = "PopulateAutoFillFields", - Type = "bool", - Value = PopulateAutoFillFields, - }); - types.Add(new OpenApiType() - { - Name = "expires_at", - Property = "ExpiresAt", - Type = "int?", - Value = ExpiresAt, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - // Message (string) maxLength - if (this.Message != null && this.Message.Length > 5000) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Message, length must be less than 5000.", new[] { "Message" }); - } - - // Subject (string) maxLength - if (this.Subject != null && this.Subject.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Subject, length must be less than 255.", new[] { "Subject" }); - } - - // Title (string) maxLength - if (this.Title != null && this.Title.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Title, length must be less than 255.", new[] { "Title" }); - } - - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedWithTemplateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedWithTemplateRequest.cs deleted file mode 100644 index 6d91c684d..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditEmbeddedWithTemplateRequest.cs +++ /dev/null @@ -1,558 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// SignatureRequestEditEmbeddedWithTemplateRequest - /// - [DataContract(Name = "SignatureRequestEditEmbeddedWithTemplateRequest")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class SignatureRequestEditEmbeddedWithTemplateRequest : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected SignatureRequestEditEmbeddedWithTemplateRequest() { } - /// - /// Initializes a new instance of the class. - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. (required). - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. (default to false). - /// Add CC email recipients. Required when a CC role exists for the Template.. - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. (required). - /// An array defining values and options for custom fields. Required when a custom field exists in the Template.. - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both.. - /// 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.. - /// The custom message in the email that will be sent to the signers.. - /// 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.. - /// Add Signers to your Templated-based Signature Request. (required). - /// signingOptions. - /// The subject in the email that will be sent to the signers.. - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. (default to false). - /// The title you want to assign to the SignatureRequest.. - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. (default to false). - public SignatureRequestEditEmbeddedWithTemplateRequest(List templateIds = default(List), bool allowDecline = false, List ccs = default(List), string clientId = default(string), List customFields = default(List), List files = default(List), List fileUrls = default(List), string message = default(string), Dictionary metadata = default(Dictionary), List signers = default(List), SubSigningOptions signingOptions = default(SubSigningOptions), string subject = default(string), bool testMode = false, string title = default(string), bool populateAutoFillFields = false) - { - - // to ensure "templateIds" is required (not null) - if (templateIds == null) - { - throw new ArgumentNullException("templateIds is a required property for SignatureRequestEditEmbeddedWithTemplateRequest and cannot be null"); - } - this.TemplateIds = templateIds; - // to ensure "clientId" is required (not null) - if (clientId == null) - { - throw new ArgumentNullException("clientId is a required property for SignatureRequestEditEmbeddedWithTemplateRequest and cannot be null"); - } - this.ClientId = clientId; - // to ensure "signers" is required (not null) - if (signers == null) - { - throw new ArgumentNullException("signers is a required property for SignatureRequestEditEmbeddedWithTemplateRequest and cannot be null"); - } - this.Signers = signers; - this.AllowDecline = allowDecline; - this.Ccs = ccs; - this.CustomFields = customFields; - this.Files = files; - this.FileUrls = fileUrls; - this.Message = message; - this.Metadata = metadata; - this.SigningOptions = signingOptions; - this.Subject = subject; - this.TestMode = testMode; - this.Title = title; - this.PopulateAutoFillFields = populateAutoFillFields; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static SignatureRequestEditEmbeddedWithTemplateRequest Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of SignatureRequestEditEmbeddedWithTemplateRequest"); - } - - return obj; - } - - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. - [DataMember(Name = "template_ids", IsRequired = true, EmitDefaultValue = true)] - public List TemplateIds { get; set; } - - /// - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. - /// - /// Client id of the app you're using to create this embedded signature request. Used for security purposes. - [DataMember(Name = "client_id", IsRequired = true, EmitDefaultValue = true)] - public string ClientId { get; set; } - - /// - /// Add Signers to your Templated-based Signature Request. - /// - /// Add Signers to your Templated-based Signature Request. - [DataMember(Name = "signers", IsRequired = true, EmitDefaultValue = true)] - public List Signers { get; set; } - - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - [DataMember(Name = "allow_decline", EmitDefaultValue = true)] - public bool AllowDecline { get; set; } - - /// - /// Add CC email recipients. Required when a CC role exists for the Template. - /// - /// Add CC email recipients. Required when a CC role exists for the Template. - [DataMember(Name = "ccs", EmitDefaultValue = true)] - public List Ccs { get; set; } - - /// - /// An array defining values and options for custom fields. Required when a custom field exists in the Template. - /// - /// An array defining values and options for custom fields. Required when a custom field exists in the Template. - [DataMember(Name = "custom_fields", EmitDefaultValue = true)] - public List CustomFields { get; set; } - - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - [DataMember(Name = "files", EmitDefaultValue = true)] - public List Files { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "file_urls", EmitDefaultValue = true)] - public List FileUrls { get; set; } - - /// - /// The custom message in the email that will be sent to the signers. - /// - /// The custom message in the email that will be sent to the signers. - [DataMember(Name = "message", EmitDefaultValue = true)] - public string Message { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "metadata", EmitDefaultValue = true)] - public Dictionary Metadata { get; set; } - - /// - /// Gets or Sets SigningOptions - /// - [DataMember(Name = "signing_options", EmitDefaultValue = true)] - public SubSigningOptions SigningOptions { get; set; } - - /// - /// The subject in the email that will be sent to the signers. - /// - /// The subject in the email that will be sent to the signers. - [DataMember(Name = "subject", EmitDefaultValue = true)] - public string Subject { get; set; } - - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - [DataMember(Name = "test_mode", EmitDefaultValue = true)] - public bool TestMode { get; set; } - - /// - /// The title you want to assign to the SignatureRequest. - /// - /// The title you want to assign to the SignatureRequest. - [DataMember(Name = "title", EmitDefaultValue = true)] - public string Title { get; set; } - - /// - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. - /// - /// Controls whether [auto fill fields](https://faq.hellosign.com/hc/en-us/articles/360051467511-Auto-Fill-Fields) can automatically populate a signer's information during signing. **NOTE:** Keep your signer's information safe by ensuring that the _signer on your signature request is the intended party_ before using this feature. - [DataMember(Name = "populate_auto_fill_fields", EmitDefaultValue = true)] - public bool PopulateAutoFillFields { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class SignatureRequestEditEmbeddedWithTemplateRequest {\n"); - sb.Append(" TemplateIds: ").Append(TemplateIds).Append("\n"); - sb.Append(" ClientId: ").Append(ClientId).Append("\n"); - sb.Append(" Signers: ").Append(Signers).Append("\n"); - sb.Append(" AllowDecline: ").Append(AllowDecline).Append("\n"); - sb.Append(" Ccs: ").Append(Ccs).Append("\n"); - sb.Append(" CustomFields: ").Append(CustomFields).Append("\n"); - sb.Append(" Files: ").Append(Files).Append("\n"); - sb.Append(" FileUrls: ").Append(FileUrls).Append("\n"); - sb.Append(" Message: ").Append(Message).Append("\n"); - sb.Append(" Metadata: ").Append(Metadata).Append("\n"); - sb.Append(" SigningOptions: ").Append(SigningOptions).Append("\n"); - sb.Append(" Subject: ").Append(Subject).Append("\n"); - sb.Append(" TestMode: ").Append(TestMode).Append("\n"); - sb.Append(" Title: ").Append(Title).Append("\n"); - sb.Append(" PopulateAutoFillFields: ").Append(PopulateAutoFillFields).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as SignatureRequestEditEmbeddedWithTemplateRequest); - } - - /// - /// Returns true if SignatureRequestEditEmbeddedWithTemplateRequest instances are equal - /// - /// Instance of SignatureRequestEditEmbeddedWithTemplateRequest to be compared - /// Boolean - public bool Equals(SignatureRequestEditEmbeddedWithTemplateRequest input) - { - if (input == null) - { - return false; - } - return - ( - this.TemplateIds == input.TemplateIds || - this.TemplateIds != null && - input.TemplateIds != null && - this.TemplateIds.SequenceEqual(input.TemplateIds) - ) && - ( - this.ClientId == input.ClientId || - (this.ClientId != null && - this.ClientId.Equals(input.ClientId)) - ) && - ( - this.Signers == input.Signers || - this.Signers != null && - input.Signers != null && - this.Signers.SequenceEqual(input.Signers) - ) && - ( - this.AllowDecline == input.AllowDecline || - this.AllowDecline.Equals(input.AllowDecline) - ) && - ( - this.Ccs == input.Ccs || - this.Ccs != null && - input.Ccs != null && - this.Ccs.SequenceEqual(input.Ccs) - ) && - ( - this.CustomFields == input.CustomFields || - this.CustomFields != null && - input.CustomFields != null && - this.CustomFields.SequenceEqual(input.CustomFields) - ) && - ( - this.Files == input.Files || - this.Files != null && - input.Files != null && - this.Files.SequenceEqual(input.Files) - ) && - ( - this.FileUrls == input.FileUrls || - this.FileUrls != null && - input.FileUrls != null && - this.FileUrls.SequenceEqual(input.FileUrls) - ) && - ( - this.Message == input.Message || - (this.Message != null && - this.Message.Equals(input.Message)) - ) && - ( - this.Metadata == input.Metadata || - this.Metadata != null && - input.Metadata != null && - this.Metadata.SequenceEqual(input.Metadata) - ) && - ( - this.SigningOptions == input.SigningOptions || - (this.SigningOptions != null && - this.SigningOptions.Equals(input.SigningOptions)) - ) && - ( - this.Subject == input.Subject || - (this.Subject != null && - this.Subject.Equals(input.Subject)) - ) && - ( - this.TestMode == input.TestMode || - this.TestMode.Equals(input.TestMode) - ) && - ( - this.Title == input.Title || - (this.Title != null && - this.Title.Equals(input.Title)) - ) && - ( - this.PopulateAutoFillFields == input.PopulateAutoFillFields || - this.PopulateAutoFillFields.Equals(input.PopulateAutoFillFields) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.TemplateIds != null) - { - hashCode = (hashCode * 59) + this.TemplateIds.GetHashCode(); - } - if (this.ClientId != null) - { - hashCode = (hashCode * 59) + this.ClientId.GetHashCode(); - } - if (this.Signers != null) - { - hashCode = (hashCode * 59) + this.Signers.GetHashCode(); - } - hashCode = (hashCode * 59) + this.AllowDecline.GetHashCode(); - if (this.Ccs != null) - { - hashCode = (hashCode * 59) + this.Ccs.GetHashCode(); - } - if (this.CustomFields != null) - { - hashCode = (hashCode * 59) + this.CustomFields.GetHashCode(); - } - if (this.Files != null) - { - hashCode = (hashCode * 59) + this.Files.GetHashCode(); - } - if (this.FileUrls != null) - { - hashCode = (hashCode * 59) + this.FileUrls.GetHashCode(); - } - if (this.Message != null) - { - hashCode = (hashCode * 59) + this.Message.GetHashCode(); - } - if (this.Metadata != null) - { - hashCode = (hashCode * 59) + this.Metadata.GetHashCode(); - } - if (this.SigningOptions != null) - { - hashCode = (hashCode * 59) + this.SigningOptions.GetHashCode(); - } - if (this.Subject != null) - { - hashCode = (hashCode * 59) + this.Subject.GetHashCode(); - } - hashCode = (hashCode * 59) + this.TestMode.GetHashCode(); - if (this.Title != null) - { - hashCode = (hashCode * 59) + this.Title.GetHashCode(); - } - hashCode = (hashCode * 59) + this.PopulateAutoFillFields.GetHashCode(); - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "template_ids", - Property = "TemplateIds", - Type = "List", - Value = TemplateIds, - }); - types.Add(new OpenApiType() - { - Name = "client_id", - Property = "ClientId", - Type = "string", - Value = ClientId, - }); - types.Add(new OpenApiType() - { - Name = "signers", - Property = "Signers", - Type = "List", - Value = Signers, - }); - types.Add(new OpenApiType() - { - Name = "allow_decline", - Property = "AllowDecline", - Type = "bool", - Value = AllowDecline, - }); - types.Add(new OpenApiType() - { - Name = "ccs", - Property = "Ccs", - Type = "List", - Value = Ccs, - }); - types.Add(new OpenApiType() - { - Name = "custom_fields", - Property = "CustomFields", - Type = "List", - Value = CustomFields, - }); - types.Add(new OpenApiType() - { - Name = "files", - Property = "Files", - Type = "List", - Value = Files, - }); - types.Add(new OpenApiType() - { - Name = "file_urls", - Property = "FileUrls", - Type = "List", - Value = FileUrls, - }); - types.Add(new OpenApiType() - { - Name = "message", - Property = "Message", - Type = "string", - Value = Message, - }); - types.Add(new OpenApiType() - { - Name = "metadata", - Property = "Metadata", - Type = "Dictionary", - Value = Metadata, - }); - types.Add(new OpenApiType() - { - Name = "signing_options", - Property = "SigningOptions", - Type = "SubSigningOptions", - Value = SigningOptions, - }); - types.Add(new OpenApiType() - { - Name = "subject", - Property = "Subject", - Type = "string", - Value = Subject, - }); - types.Add(new OpenApiType() - { - Name = "test_mode", - Property = "TestMode", - Type = "bool", - Value = TestMode, - }); - types.Add(new OpenApiType() - { - Name = "title", - Property = "Title", - Type = "string", - Value = Title, - }); - types.Add(new OpenApiType() - { - Name = "populate_auto_fill_fields", - Property = "PopulateAutoFillFields", - Type = "bool", - Value = PopulateAutoFillFields, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - // Message (string) maxLength - if (this.Message != null && this.Message.Length > 5000) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Message, length must be less than 5000.", new[] { "Message" }); - } - - // Subject (string) maxLength - if (this.Subject != null && this.Subject.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Subject, length must be less than 255.", new[] { "Subject" }); - } - - // Title (string) maxLength - if (this.Title != null && this.Title.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Title, length must be less than 255.", new[] { "Title" }); - } - - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditRequest.cs deleted file mode 100644 index 02b19c235..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditRequest.cs +++ /dev/null @@ -1,817 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// SignatureRequestEditRequest - /// - [DataContract(Name = "SignatureRequestEditRequest")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class SignatureRequestEditRequest : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected SignatureRequestEditRequest() { } - /// - /// Initializes a new instance of the class. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both.. - /// 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.. - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both.. - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both.. - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. (default to false). - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan and higher. (default to false). - /// A list describing the attachments. - /// The email addresses that should be CCed.. - /// The client id of the API App you want to associate with this request. Used to apply the branding and callback url defined for the app.. - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template.. - /// fieldOptions. - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`.. - /// Conditional Logic rules for fields defined in `form_fields_per_document`.. - /// 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`. - /// Enables automatic Text Tag removal when set to true. **NOTE:** Removing text tags this way can cause unwanted clipping. We recommend leaving this setting on `false` and instead hiding your text tags using white text or a similar approach. See the [Text Tags Walkthrough](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) for more information. (default to false). - /// Send with a value of `true` if you wish to enable [Qualified Electronic Signatures](https://www.hellosign.com/features/qualified-electronic-signatures) (QES), which requires a face-to-face call to verify the signer's identity.<br> **NOTE:** QES is only available on the Premium API plan as an add-on purchase. Cannot be used in `test_mode`. Only works on requests with one signer. (default to false). - /// Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br> **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. (default to false). - /// The custom message in the email that will be sent to the signers.. - /// 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. - /// The URL you want signers redirected to after they successfully sign.. - /// The subject in the email that will be sent to the signers.. - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. (default to false). - /// The title you want to assign to the SignatureRequest.. - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. (default to false). - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details.. - public SignatureRequestEditRequest(List files = default(List), List fileUrls = default(List), List signers = default(List), List groupedSigners = default(List), bool allowDecline = false, bool allowReassign = false, List attachments = default(List), List ccEmailAddresses = default(List), string clientId = default(string), List customFields = default(List), SubFieldOptions fieldOptions = default(SubFieldOptions), List formFieldGroups = default(List), List formFieldRules = default(List), List formFieldsPerDocument = default(List), bool hideTextTags = false, bool isQualifiedSignature = false, bool isEid = false, string message = default(string), Dictionary metadata = default(Dictionary), SubSigningOptions signingOptions = default(SubSigningOptions), string signingRedirectUrl = default(string), string subject = default(string), bool testMode = false, string title = default(string), bool useTextTags = false, int? expiresAt = default(int?)) - { - - this.Files = files; - this.FileUrls = fileUrls; - this.Signers = signers; - this.GroupedSigners = groupedSigners; - this.AllowDecline = allowDecline; - this.AllowReassign = allowReassign; - this.Attachments = attachments; - this.CcEmailAddresses = ccEmailAddresses; - this.ClientId = clientId; - this.CustomFields = customFields; - this.FieldOptions = fieldOptions; - this.FormFieldGroups = formFieldGroups; - this.FormFieldRules = formFieldRules; - this.FormFieldsPerDocument = formFieldsPerDocument; - this.HideTextTags = hideTextTags; - this.IsQualifiedSignature = isQualifiedSignature; - this.IsEid = isEid; - this.Message = message; - this.Metadata = metadata; - this.SigningOptions = signingOptions; - this.SigningRedirectUrl = signingRedirectUrl; - this.Subject = subject; - this.TestMode = testMode; - this.Title = title; - this.UseTextTags = useTextTags; - this.ExpiresAt = expiresAt; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static SignatureRequestEditRequest Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of SignatureRequestEditRequest"); - } - - return obj; - } - - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - [DataMember(Name = "files", EmitDefaultValue = true)] - public List Files { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "file_urls", EmitDefaultValue = true)] - public List FileUrls { get; set; } - - /// - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - /// - /// Add Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - [DataMember(Name = "signers", EmitDefaultValue = true)] - public List Signers { get; set; } - - /// - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - /// - /// Add Grouped Signers to your Signature Request. This endpoint requires either **signers** or **grouped_signers**, but not both. - [DataMember(Name = "grouped_signers", EmitDefaultValue = true)] - public List GroupedSigners { get; set; } - - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - [DataMember(Name = "allow_decline", EmitDefaultValue = true)] - public bool AllowDecline { get; set; } - - /// - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan and higher. - /// - /// Allows signers to reassign their signature requests to other signers if set to `true`. Defaults to `false`. **NOTE:** Only available for Premium plan and higher. - [DataMember(Name = "allow_reassign", EmitDefaultValue = true)] - public bool AllowReassign { get; set; } - - /// - /// A list describing the attachments - /// - /// A list describing the attachments - [DataMember(Name = "attachments", EmitDefaultValue = true)] - public List Attachments { get; set; } - - /// - /// The email addresses that should be CCed. - /// - /// The email addresses that should be CCed. - [DataMember(Name = "cc_email_addresses", EmitDefaultValue = true)] - public List CcEmailAddresses { get; set; } - - /// - /// The client id of the API App you want to associate with this request. Used to apply the branding and callback url defined for the app. - /// - /// The client id of the API App you want to associate with this request. Used to apply the branding and callback url defined for the app. - [DataMember(Name = "client_id", EmitDefaultValue = true)] - public string ClientId { get; set; } - - /// - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template. - /// - /// When used together with merge fields, `custom_fields` allows users to add pre-filled data to their signature requests. Pre-filled data can be used with \"send-once\" signature requests by adding merge fields with `form_fields_per_document` or [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) while passing values back with `custom_fields` together in one API call. For using pre-filled on repeatable signature requests, merge fields are added to templates in the Dropbox Sign UI or by calling [/template/create_embedded_draft](/api/reference/operation/templateCreateEmbeddedDraft) and then passing `custom_fields` on subsequent signature requests referencing that template. - [DataMember(Name = "custom_fields", EmitDefaultValue = true)] - public List CustomFields { get; set; } - - /// - /// Gets or Sets FieldOptions - /// - [DataMember(Name = "field_options", EmitDefaultValue = true)] - public SubFieldOptions FieldOptions { get; set; } - - /// - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`. - /// - /// Group information for fields defined in `form_fields_per_document`. String-indexed JSON array with `group_label` and `requirement` keys. `form_fields_per_document` must contain fields referencing a group defined in `form_field_groups`. - [DataMember(Name = "form_field_groups", EmitDefaultValue = true)] - public List FormFieldGroups { get; set; } - - /// - /// Conditional Logic rules for fields defined in `form_fields_per_document`. - /// - /// Conditional Logic rules for fields defined in `form_fields_per_document`. - [DataMember(Name = "form_field_rules", EmitDefaultValue = true)] - public List FormFieldRules { get; set; } - - /// - /// 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` - /// - /// 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` - [DataMember(Name = "form_fields_per_document", EmitDefaultValue = true)] - public List FormFieldsPerDocument { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "hide_text_tags", EmitDefaultValue = true)] - public bool HideTextTags { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "is_qualified_signature", EmitDefaultValue = true)] - [Obsolete] - public bool IsQualifiedSignature { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "is_eid", EmitDefaultValue = true)] - public bool IsEid { get; set; } - - /// - /// The custom message in the email that will be sent to the signers. - /// - /// The custom message in the email that will be sent to the signers. - [DataMember(Name = "message", EmitDefaultValue = true)] - public string Message { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "metadata", EmitDefaultValue = true)] - public Dictionary Metadata { get; set; } - - /// - /// Gets or Sets SigningOptions - /// - [DataMember(Name = "signing_options", EmitDefaultValue = true)] - public SubSigningOptions SigningOptions { get; set; } - - /// - /// The URL you want signers redirected to after they successfully sign. - /// - /// The URL you want signers redirected to after they successfully sign. - [DataMember(Name = "signing_redirect_url", EmitDefaultValue = true)] - public string SigningRedirectUrl { get; set; } - - /// - /// The subject in the email that will be sent to the signers. - /// - /// The subject in the email that will be sent to the signers. - [DataMember(Name = "subject", EmitDefaultValue = true)] - public string Subject { get; set; } - - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - [DataMember(Name = "test_mode", EmitDefaultValue = true)] - public bool TestMode { get; set; } - - /// - /// The title you want to assign to the SignatureRequest. - /// - /// The title you want to assign to the SignatureRequest. - [DataMember(Name = "title", EmitDefaultValue = true)] - public string Title { get; set; } - - /// - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. - /// - /// Send with a value of `true` if you wish to enable [Text Tags](https://app.hellosign.com/api/textTagsWalkthrough#TextTagIntro) parsing in your document. Defaults to disabled, or `false`. - [DataMember(Name = "use_text_tags", EmitDefaultValue = true)] - public bool UseTextTags { get; set; } - - /// - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details. - /// - /// When the signature request will expire. Unsigned signatures will be moved to the expired status, and no longer signable. See [Signature Request Expiration Date](https://developers.hellosign.com/docs/signature-request/expiration/) for details. - [DataMember(Name = "expires_at", EmitDefaultValue = true)] - public int? ExpiresAt { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class SignatureRequestEditRequest {\n"); - sb.Append(" Files: ").Append(Files).Append("\n"); - sb.Append(" FileUrls: ").Append(FileUrls).Append("\n"); - sb.Append(" Signers: ").Append(Signers).Append("\n"); - sb.Append(" GroupedSigners: ").Append(GroupedSigners).Append("\n"); - sb.Append(" AllowDecline: ").Append(AllowDecline).Append("\n"); - sb.Append(" AllowReassign: ").Append(AllowReassign).Append("\n"); - sb.Append(" Attachments: ").Append(Attachments).Append("\n"); - sb.Append(" CcEmailAddresses: ").Append(CcEmailAddresses).Append("\n"); - sb.Append(" ClientId: ").Append(ClientId).Append("\n"); - sb.Append(" CustomFields: ").Append(CustomFields).Append("\n"); - sb.Append(" FieldOptions: ").Append(FieldOptions).Append("\n"); - sb.Append(" FormFieldGroups: ").Append(FormFieldGroups).Append("\n"); - sb.Append(" FormFieldRules: ").Append(FormFieldRules).Append("\n"); - sb.Append(" FormFieldsPerDocument: ").Append(FormFieldsPerDocument).Append("\n"); - sb.Append(" HideTextTags: ").Append(HideTextTags).Append("\n"); - sb.Append(" IsQualifiedSignature: ").Append(IsQualifiedSignature).Append("\n"); - sb.Append(" IsEid: ").Append(IsEid).Append("\n"); - sb.Append(" Message: ").Append(Message).Append("\n"); - sb.Append(" Metadata: ").Append(Metadata).Append("\n"); - sb.Append(" SigningOptions: ").Append(SigningOptions).Append("\n"); - sb.Append(" SigningRedirectUrl: ").Append(SigningRedirectUrl).Append("\n"); - sb.Append(" Subject: ").Append(Subject).Append("\n"); - sb.Append(" TestMode: ").Append(TestMode).Append("\n"); - sb.Append(" Title: ").Append(Title).Append("\n"); - sb.Append(" UseTextTags: ").Append(UseTextTags).Append("\n"); - sb.Append(" ExpiresAt: ").Append(ExpiresAt).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as SignatureRequestEditRequest); - } - - /// - /// Returns true if SignatureRequestEditRequest instances are equal - /// - /// Instance of SignatureRequestEditRequest to be compared - /// Boolean - public bool Equals(SignatureRequestEditRequest input) - { - if (input == null) - { - return false; - } - return - ( - this.Files == input.Files || - this.Files != null && - input.Files != null && - this.Files.SequenceEqual(input.Files) - ) && - ( - this.FileUrls == input.FileUrls || - this.FileUrls != null && - input.FileUrls != null && - this.FileUrls.SequenceEqual(input.FileUrls) - ) && - ( - this.Signers == input.Signers || - this.Signers != null && - input.Signers != null && - this.Signers.SequenceEqual(input.Signers) - ) && - ( - this.GroupedSigners == input.GroupedSigners || - this.GroupedSigners != null && - input.GroupedSigners != null && - this.GroupedSigners.SequenceEqual(input.GroupedSigners) - ) && - ( - this.AllowDecline == input.AllowDecline || - this.AllowDecline.Equals(input.AllowDecline) - ) && - ( - this.AllowReassign == input.AllowReassign || - this.AllowReassign.Equals(input.AllowReassign) - ) && - ( - this.Attachments == input.Attachments || - this.Attachments != null && - input.Attachments != null && - this.Attachments.SequenceEqual(input.Attachments) - ) && - ( - this.CcEmailAddresses == input.CcEmailAddresses || - this.CcEmailAddresses != null && - input.CcEmailAddresses != null && - this.CcEmailAddresses.SequenceEqual(input.CcEmailAddresses) - ) && - ( - this.ClientId == input.ClientId || - (this.ClientId != null && - this.ClientId.Equals(input.ClientId)) - ) && - ( - this.CustomFields == input.CustomFields || - this.CustomFields != null && - input.CustomFields != null && - this.CustomFields.SequenceEqual(input.CustomFields) - ) && - ( - this.FieldOptions == input.FieldOptions || - (this.FieldOptions != null && - this.FieldOptions.Equals(input.FieldOptions)) - ) && - ( - this.FormFieldGroups == input.FormFieldGroups || - this.FormFieldGroups != null && - input.FormFieldGroups != null && - this.FormFieldGroups.SequenceEqual(input.FormFieldGroups) - ) && - ( - this.FormFieldRules == input.FormFieldRules || - this.FormFieldRules != null && - input.FormFieldRules != null && - this.FormFieldRules.SequenceEqual(input.FormFieldRules) - ) && - ( - this.FormFieldsPerDocument == input.FormFieldsPerDocument || - this.FormFieldsPerDocument != null && - input.FormFieldsPerDocument != null && - this.FormFieldsPerDocument.SequenceEqual(input.FormFieldsPerDocument) - ) && - ( - this.HideTextTags == input.HideTextTags || - this.HideTextTags.Equals(input.HideTextTags) - ) && - ( - this.IsQualifiedSignature == input.IsQualifiedSignature || - this.IsQualifiedSignature.Equals(input.IsQualifiedSignature) - ) && - ( - this.IsEid == input.IsEid || - this.IsEid.Equals(input.IsEid) - ) && - ( - this.Message == input.Message || - (this.Message != null && - this.Message.Equals(input.Message)) - ) && - ( - this.Metadata == input.Metadata || - this.Metadata != null && - input.Metadata != null && - this.Metadata.SequenceEqual(input.Metadata) - ) && - ( - this.SigningOptions == input.SigningOptions || - (this.SigningOptions != null && - this.SigningOptions.Equals(input.SigningOptions)) - ) && - ( - this.SigningRedirectUrl == input.SigningRedirectUrl || - (this.SigningRedirectUrl != null && - this.SigningRedirectUrl.Equals(input.SigningRedirectUrl)) - ) && - ( - this.Subject == input.Subject || - (this.Subject != null && - this.Subject.Equals(input.Subject)) - ) && - ( - this.TestMode == input.TestMode || - this.TestMode.Equals(input.TestMode) - ) && - ( - this.Title == input.Title || - (this.Title != null && - this.Title.Equals(input.Title)) - ) && - ( - this.UseTextTags == input.UseTextTags || - this.UseTextTags.Equals(input.UseTextTags) - ) && - ( - this.ExpiresAt == input.ExpiresAt || - (this.ExpiresAt != null && - this.ExpiresAt.Equals(input.ExpiresAt)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Files != null) - { - hashCode = (hashCode * 59) + this.Files.GetHashCode(); - } - if (this.FileUrls != null) - { - hashCode = (hashCode * 59) + this.FileUrls.GetHashCode(); - } - if (this.Signers != null) - { - hashCode = (hashCode * 59) + this.Signers.GetHashCode(); - } - if (this.GroupedSigners != null) - { - hashCode = (hashCode * 59) + this.GroupedSigners.GetHashCode(); - } - hashCode = (hashCode * 59) + this.AllowDecline.GetHashCode(); - hashCode = (hashCode * 59) + this.AllowReassign.GetHashCode(); - if (this.Attachments != null) - { - hashCode = (hashCode * 59) + this.Attachments.GetHashCode(); - } - if (this.CcEmailAddresses != null) - { - hashCode = (hashCode * 59) + this.CcEmailAddresses.GetHashCode(); - } - if (this.ClientId != null) - { - hashCode = (hashCode * 59) + this.ClientId.GetHashCode(); - } - if (this.CustomFields != null) - { - hashCode = (hashCode * 59) + this.CustomFields.GetHashCode(); - } - if (this.FieldOptions != null) - { - hashCode = (hashCode * 59) + this.FieldOptions.GetHashCode(); - } - if (this.FormFieldGroups != null) - { - hashCode = (hashCode * 59) + this.FormFieldGroups.GetHashCode(); - } - if (this.FormFieldRules != null) - { - hashCode = (hashCode * 59) + this.FormFieldRules.GetHashCode(); - } - if (this.FormFieldsPerDocument != null) - { - hashCode = (hashCode * 59) + this.FormFieldsPerDocument.GetHashCode(); - } - hashCode = (hashCode * 59) + this.HideTextTags.GetHashCode(); - hashCode = (hashCode * 59) + this.IsQualifiedSignature.GetHashCode(); - hashCode = (hashCode * 59) + this.IsEid.GetHashCode(); - if (this.Message != null) - { - hashCode = (hashCode * 59) + this.Message.GetHashCode(); - } - if (this.Metadata != null) - { - hashCode = (hashCode * 59) + this.Metadata.GetHashCode(); - } - if (this.SigningOptions != null) - { - hashCode = (hashCode * 59) + this.SigningOptions.GetHashCode(); - } - if (this.SigningRedirectUrl != null) - { - hashCode = (hashCode * 59) + this.SigningRedirectUrl.GetHashCode(); - } - if (this.Subject != null) - { - hashCode = (hashCode * 59) + this.Subject.GetHashCode(); - } - hashCode = (hashCode * 59) + this.TestMode.GetHashCode(); - if (this.Title != null) - { - hashCode = (hashCode * 59) + this.Title.GetHashCode(); - } - hashCode = (hashCode * 59) + this.UseTextTags.GetHashCode(); - if (this.ExpiresAt != null) - { - hashCode = (hashCode * 59) + this.ExpiresAt.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "files", - Property = "Files", - Type = "List", - Value = Files, - }); - types.Add(new OpenApiType() - { - Name = "file_urls", - Property = "FileUrls", - Type = "List", - Value = FileUrls, - }); - types.Add(new OpenApiType() - { - Name = "signers", - Property = "Signers", - Type = "List", - Value = Signers, - }); - types.Add(new OpenApiType() - { - Name = "grouped_signers", - Property = "GroupedSigners", - Type = "List", - Value = GroupedSigners, - }); - types.Add(new OpenApiType() - { - Name = "allow_decline", - Property = "AllowDecline", - Type = "bool", - Value = AllowDecline, - }); - types.Add(new OpenApiType() - { - Name = "allow_reassign", - Property = "AllowReassign", - Type = "bool", - Value = AllowReassign, - }); - types.Add(new OpenApiType() - { - Name = "attachments", - Property = "Attachments", - Type = "List", - Value = Attachments, - }); - types.Add(new OpenApiType() - { - Name = "cc_email_addresses", - Property = "CcEmailAddresses", - Type = "List", - Value = CcEmailAddresses, - }); - types.Add(new OpenApiType() - { - Name = "client_id", - Property = "ClientId", - Type = "string", - Value = ClientId, - }); - types.Add(new OpenApiType() - { - Name = "custom_fields", - Property = "CustomFields", - Type = "List", - Value = CustomFields, - }); - types.Add(new OpenApiType() - { - Name = "field_options", - Property = "FieldOptions", - Type = "SubFieldOptions", - Value = FieldOptions, - }); - types.Add(new OpenApiType() - { - Name = "form_field_groups", - Property = "FormFieldGroups", - Type = "List", - Value = FormFieldGroups, - }); - types.Add(new OpenApiType() - { - Name = "form_field_rules", - Property = "FormFieldRules", - Type = "List", - Value = FormFieldRules, - }); - types.Add(new OpenApiType() - { - Name = "form_fields_per_document", - Property = "FormFieldsPerDocument", - Type = "List", - Value = FormFieldsPerDocument, - }); - types.Add(new OpenApiType() - { - Name = "hide_text_tags", - Property = "HideTextTags", - Type = "bool", - Value = HideTextTags, - }); - types.Add(new OpenApiType() - { - Name = "is_qualified_signature", - Property = "IsQualifiedSignature", - Type = "bool", - Value = IsQualifiedSignature, - }); - types.Add(new OpenApiType() - { - Name = "is_eid", - Property = "IsEid", - Type = "bool", - Value = IsEid, - }); - types.Add(new OpenApiType() - { - Name = "message", - Property = "Message", - Type = "string", - Value = Message, - }); - types.Add(new OpenApiType() - { - Name = "metadata", - Property = "Metadata", - Type = "Dictionary", - Value = Metadata, - }); - types.Add(new OpenApiType() - { - Name = "signing_options", - Property = "SigningOptions", - Type = "SubSigningOptions", - Value = SigningOptions, - }); - types.Add(new OpenApiType() - { - Name = "signing_redirect_url", - Property = "SigningRedirectUrl", - Type = "string", - Value = SigningRedirectUrl, - }); - types.Add(new OpenApiType() - { - Name = "subject", - Property = "Subject", - Type = "string", - Value = Subject, - }); - types.Add(new OpenApiType() - { - Name = "test_mode", - Property = "TestMode", - Type = "bool", - Value = TestMode, - }); - types.Add(new OpenApiType() - { - Name = "title", - Property = "Title", - Type = "string", - Value = Title, - }); - types.Add(new OpenApiType() - { - Name = "use_text_tags", - Property = "UseTextTags", - Type = "bool", - Value = UseTextTags, - }); - types.Add(new OpenApiType() - { - Name = "expires_at", - Property = "ExpiresAt", - Type = "int?", - Value = ExpiresAt, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - // Message (string) maxLength - if (this.Message != null && this.Message.Length > 5000) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Message, length must be less than 5000.", new[] { "Message" }); - } - - // Subject (string) maxLength - if (this.Subject != null && this.Subject.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Subject, length must be less than 255.", new[] { "Subject" }); - } - - // Title (string) maxLength - if (this.Title != null && this.Title.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Title, length must be less than 255.", new[] { "Title" }); - } - - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditWithTemplateRequest.cs b/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditWithTemplateRequest.cs deleted file mode 100644 index 437003358..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/SignatureRequestEditWithTemplateRequest.cs +++ /dev/null @@ -1,602 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// SignatureRequestEditWithTemplateRequest - /// - [DataContract(Name = "SignatureRequestEditWithTemplateRequest")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class SignatureRequestEditWithTemplateRequest : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected SignatureRequestEditWithTemplateRequest() { } - /// - /// Initializes a new instance of the class. - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. (required). - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. (default to false). - /// Add CC email recipients. Required when a CC role exists for the Template.. - /// Client id of the app to associate with the signature request. Used to apply the branding and callback url defined for the app.. - /// An array defining values and options for custom fields. Required when a custom field exists in the Template.. - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both.. - /// 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.. - /// Send with a value of `true` if you wish to enable [Qualified Electronic Signatures](https://www.hellosign.com/features/qualified-electronic-signatures) (QES), which requires a face-to-face call to verify the signer's identity.<br> **NOTE:** QES is only available on the Premium API plan as an add-on purchase. Cannot be used in `test_mode`. Only works on requests with one signer. (default to false). - /// Send with a value of `true` if you wish to enable [electronic identification (eID)](https://www.hellosign.com/features/electronic-id), which requires the signer to verify their identity with an eID provider to sign a document.<br> **NOTE:** eID is only available on the Premium API plan. Cannot be used in `test_mode`. Only works on requests with one signer. (default to false). - /// The custom message in the email that will be sent to the signers.. - /// 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.. - /// Add Signers to your Templated-based Signature Request. (required). - /// signingOptions. - /// The URL you want signers redirected to after they successfully sign.. - /// The subject in the email that will be sent to the signers.. - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. (default to false). - /// The title you want to assign to the SignatureRequest.. - public SignatureRequestEditWithTemplateRequest(List templateIds = default(List), bool allowDecline = false, List ccs = default(List), string clientId = default(string), List customFields = default(List), List files = default(List), List fileUrls = default(List), bool isQualifiedSignature = false, bool isEid = false, string message = default(string), Dictionary metadata = default(Dictionary), List signers = default(List), SubSigningOptions signingOptions = default(SubSigningOptions), string signingRedirectUrl = default(string), string subject = default(string), bool testMode = false, string title = default(string)) - { - - // to ensure "templateIds" is required (not null) - if (templateIds == null) - { - throw new ArgumentNullException("templateIds is a required property for SignatureRequestEditWithTemplateRequest and cannot be null"); - } - this.TemplateIds = templateIds; - // to ensure "signers" is required (not null) - if (signers == null) - { - throw new ArgumentNullException("signers is a required property for SignatureRequestEditWithTemplateRequest and cannot be null"); - } - this.Signers = signers; - this.AllowDecline = allowDecline; - this.Ccs = ccs; - this.ClientId = clientId; - this.CustomFields = customFields; - this.Files = files; - this.FileUrls = fileUrls; - this.IsQualifiedSignature = isQualifiedSignature; - this.IsEid = isEid; - this.Message = message; - this.Metadata = metadata; - this.SigningOptions = signingOptions; - this.SigningRedirectUrl = signingRedirectUrl; - this.Subject = subject; - this.TestMode = testMode; - this.Title = title; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static SignatureRequestEditWithTemplateRequest Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of SignatureRequestEditWithTemplateRequest"); - } - - return obj; - } - - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. - /// - /// Use `template_ids` to create a SignatureRequest from one or more templates, in the order in which the template will be used. - [DataMember(Name = "template_ids", IsRequired = true, EmitDefaultValue = true)] - public List TemplateIds { get; set; } - - /// - /// Add Signers to your Templated-based Signature Request. - /// - /// Add Signers to your Templated-based Signature Request. - [DataMember(Name = "signers", IsRequired = true, EmitDefaultValue = true)] - public List Signers { get; set; } - - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - /// - /// Allows signers to decline to sign a document if `true`. Defaults to `false`. - [DataMember(Name = "allow_decline", EmitDefaultValue = true)] - public bool AllowDecline { get; set; } - - /// - /// Add CC email recipients. Required when a CC role exists for the Template. - /// - /// Add CC email recipients. Required when a CC role exists for the Template. - [DataMember(Name = "ccs", EmitDefaultValue = true)] - public List Ccs { get; set; } - - /// - /// Client id of the app to associate with the signature request. Used to apply the branding and callback url defined for the app. - /// - /// Client id of the app to associate with the signature request. Used to apply the branding and callback url defined for the app. - [DataMember(Name = "client_id", EmitDefaultValue = true)] - public string ClientId { get; set; } - - /// - /// An array defining values and options for custom fields. Required when a custom field exists in the Template. - /// - /// An array defining values and options for custom fields. Required when a custom field exists in the Template. - [DataMember(Name = "custom_fields", EmitDefaultValue = true)] - public List CustomFields { get; set; } - - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - /// - /// Use `files[]` to indicate the uploaded file(s) to send for signature. This endpoint requires either **files** or **file_urls[]**, but not both. - [DataMember(Name = "files", EmitDefaultValue = true)] - public List Files { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "file_urls", EmitDefaultValue = true)] - public List FileUrls { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "is_qualified_signature", EmitDefaultValue = true)] - [Obsolete] - public bool IsQualifiedSignature { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "is_eid", EmitDefaultValue = true)] - public bool IsEid { get; set; } - - /// - /// The custom message in the email that will be sent to the signers. - /// - /// The custom message in the email that will be sent to the signers. - [DataMember(Name = "message", EmitDefaultValue = true)] - public string Message { get; set; } - - /// - /// 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. - /// - /// 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. - [DataMember(Name = "metadata", EmitDefaultValue = true)] - public Dictionary Metadata { get; set; } - - /// - /// Gets or Sets SigningOptions - /// - [DataMember(Name = "signing_options", EmitDefaultValue = true)] - public SubSigningOptions SigningOptions { get; set; } - - /// - /// The URL you want signers redirected to after they successfully sign. - /// - /// The URL you want signers redirected to after they successfully sign. - [DataMember(Name = "signing_redirect_url", EmitDefaultValue = true)] - public string SigningRedirectUrl { get; set; } - - /// - /// The subject in the email that will be sent to the signers. - /// - /// The subject in the email that will be sent to the signers. - [DataMember(Name = "subject", EmitDefaultValue = true)] - public string Subject { get; set; } - - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - /// - /// Whether this is a test, the signature request will not be legally binding if set to `true`. Defaults to `false`. - [DataMember(Name = "test_mode", EmitDefaultValue = true)] - public bool TestMode { get; set; } - - /// - /// The title you want to assign to the SignatureRequest. - /// - /// The title you want to assign to the SignatureRequest. - [DataMember(Name = "title", EmitDefaultValue = true)] - public string Title { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class SignatureRequestEditWithTemplateRequest {\n"); - sb.Append(" TemplateIds: ").Append(TemplateIds).Append("\n"); - sb.Append(" Signers: ").Append(Signers).Append("\n"); - sb.Append(" AllowDecline: ").Append(AllowDecline).Append("\n"); - sb.Append(" Ccs: ").Append(Ccs).Append("\n"); - sb.Append(" ClientId: ").Append(ClientId).Append("\n"); - sb.Append(" CustomFields: ").Append(CustomFields).Append("\n"); - sb.Append(" Files: ").Append(Files).Append("\n"); - sb.Append(" FileUrls: ").Append(FileUrls).Append("\n"); - sb.Append(" IsQualifiedSignature: ").Append(IsQualifiedSignature).Append("\n"); - sb.Append(" IsEid: ").Append(IsEid).Append("\n"); - sb.Append(" Message: ").Append(Message).Append("\n"); - sb.Append(" Metadata: ").Append(Metadata).Append("\n"); - sb.Append(" SigningOptions: ").Append(SigningOptions).Append("\n"); - sb.Append(" SigningRedirectUrl: ").Append(SigningRedirectUrl).Append("\n"); - sb.Append(" Subject: ").Append(Subject).Append("\n"); - sb.Append(" TestMode: ").Append(TestMode).Append("\n"); - sb.Append(" Title: ").Append(Title).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as SignatureRequestEditWithTemplateRequest); - } - - /// - /// Returns true if SignatureRequestEditWithTemplateRequest instances are equal - /// - /// Instance of SignatureRequestEditWithTemplateRequest to be compared - /// Boolean - public bool Equals(SignatureRequestEditWithTemplateRequest input) - { - if (input == null) - { - return false; - } - return - ( - this.TemplateIds == input.TemplateIds || - this.TemplateIds != null && - input.TemplateIds != null && - this.TemplateIds.SequenceEqual(input.TemplateIds) - ) && - ( - this.Signers == input.Signers || - this.Signers != null && - input.Signers != null && - this.Signers.SequenceEqual(input.Signers) - ) && - ( - this.AllowDecline == input.AllowDecline || - this.AllowDecline.Equals(input.AllowDecline) - ) && - ( - this.Ccs == input.Ccs || - this.Ccs != null && - input.Ccs != null && - this.Ccs.SequenceEqual(input.Ccs) - ) && - ( - this.ClientId == input.ClientId || - (this.ClientId != null && - this.ClientId.Equals(input.ClientId)) - ) && - ( - this.CustomFields == input.CustomFields || - this.CustomFields != null && - input.CustomFields != null && - this.CustomFields.SequenceEqual(input.CustomFields) - ) && - ( - this.Files == input.Files || - this.Files != null && - input.Files != null && - this.Files.SequenceEqual(input.Files) - ) && - ( - this.FileUrls == input.FileUrls || - this.FileUrls != null && - input.FileUrls != null && - this.FileUrls.SequenceEqual(input.FileUrls) - ) && - ( - this.IsQualifiedSignature == input.IsQualifiedSignature || - this.IsQualifiedSignature.Equals(input.IsQualifiedSignature) - ) && - ( - this.IsEid == input.IsEid || - this.IsEid.Equals(input.IsEid) - ) && - ( - this.Message == input.Message || - (this.Message != null && - this.Message.Equals(input.Message)) - ) && - ( - this.Metadata == input.Metadata || - this.Metadata != null && - input.Metadata != null && - this.Metadata.SequenceEqual(input.Metadata) - ) && - ( - this.SigningOptions == input.SigningOptions || - (this.SigningOptions != null && - this.SigningOptions.Equals(input.SigningOptions)) - ) && - ( - this.SigningRedirectUrl == input.SigningRedirectUrl || - (this.SigningRedirectUrl != null && - this.SigningRedirectUrl.Equals(input.SigningRedirectUrl)) - ) && - ( - this.Subject == input.Subject || - (this.Subject != null && - this.Subject.Equals(input.Subject)) - ) && - ( - this.TestMode == input.TestMode || - this.TestMode.Equals(input.TestMode) - ) && - ( - this.Title == input.Title || - (this.Title != null && - this.Title.Equals(input.Title)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.TemplateIds != null) - { - hashCode = (hashCode * 59) + this.TemplateIds.GetHashCode(); - } - if (this.Signers != null) - { - hashCode = (hashCode * 59) + this.Signers.GetHashCode(); - } - hashCode = (hashCode * 59) + this.AllowDecline.GetHashCode(); - if (this.Ccs != null) - { - hashCode = (hashCode * 59) + this.Ccs.GetHashCode(); - } - if (this.ClientId != null) - { - hashCode = (hashCode * 59) + this.ClientId.GetHashCode(); - } - if (this.CustomFields != null) - { - hashCode = (hashCode * 59) + this.CustomFields.GetHashCode(); - } - if (this.Files != null) - { - hashCode = (hashCode * 59) + this.Files.GetHashCode(); - } - if (this.FileUrls != null) - { - hashCode = (hashCode * 59) + this.FileUrls.GetHashCode(); - } - hashCode = (hashCode * 59) + this.IsQualifiedSignature.GetHashCode(); - hashCode = (hashCode * 59) + this.IsEid.GetHashCode(); - if (this.Message != null) - { - hashCode = (hashCode * 59) + this.Message.GetHashCode(); - } - if (this.Metadata != null) - { - hashCode = (hashCode * 59) + this.Metadata.GetHashCode(); - } - if (this.SigningOptions != null) - { - hashCode = (hashCode * 59) + this.SigningOptions.GetHashCode(); - } - if (this.SigningRedirectUrl != null) - { - hashCode = (hashCode * 59) + this.SigningRedirectUrl.GetHashCode(); - } - if (this.Subject != null) - { - hashCode = (hashCode * 59) + this.Subject.GetHashCode(); - } - hashCode = (hashCode * 59) + this.TestMode.GetHashCode(); - if (this.Title != null) - { - hashCode = (hashCode * 59) + this.Title.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "template_ids", - Property = "TemplateIds", - Type = "List", - Value = TemplateIds, - }); - types.Add(new OpenApiType() - { - Name = "signers", - Property = "Signers", - Type = "List", - Value = Signers, - }); - types.Add(new OpenApiType() - { - Name = "allow_decline", - Property = "AllowDecline", - Type = "bool", - Value = AllowDecline, - }); - types.Add(new OpenApiType() - { - Name = "ccs", - Property = "Ccs", - Type = "List", - Value = Ccs, - }); - types.Add(new OpenApiType() - { - Name = "client_id", - Property = "ClientId", - Type = "string", - Value = ClientId, - }); - types.Add(new OpenApiType() - { - Name = "custom_fields", - Property = "CustomFields", - Type = "List", - Value = CustomFields, - }); - types.Add(new OpenApiType() - { - Name = "files", - Property = "Files", - Type = "List", - Value = Files, - }); - types.Add(new OpenApiType() - { - Name = "file_urls", - Property = "FileUrls", - Type = "List", - Value = FileUrls, - }); - types.Add(new OpenApiType() - { - Name = "is_qualified_signature", - Property = "IsQualifiedSignature", - Type = "bool", - Value = IsQualifiedSignature, - }); - types.Add(new OpenApiType() - { - Name = "is_eid", - Property = "IsEid", - Type = "bool", - Value = IsEid, - }); - types.Add(new OpenApiType() - { - Name = "message", - Property = "Message", - Type = "string", - Value = Message, - }); - types.Add(new OpenApiType() - { - Name = "metadata", - Property = "Metadata", - Type = "Dictionary", - Value = Metadata, - }); - types.Add(new OpenApiType() - { - Name = "signing_options", - Property = "SigningOptions", - Type = "SubSigningOptions", - Value = SigningOptions, - }); - types.Add(new OpenApiType() - { - Name = "signing_redirect_url", - Property = "SigningRedirectUrl", - Type = "string", - Value = SigningRedirectUrl, - }); - types.Add(new OpenApiType() - { - Name = "subject", - Property = "Subject", - Type = "string", - Value = Subject, - }); - types.Add(new OpenApiType() - { - Name = "test_mode", - Property = "TestMode", - Type = "bool", - Value = TestMode, - }); - types.Add(new OpenApiType() - { - Name = "title", - Property = "Title", - Type = "string", - Value = Title, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - // Message (string) maxLength - if (this.Message != null && this.Message.Length > 5000) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Message, length must be less than 5000.", new[] { "Message" }); - } - - // Subject (string) maxLength - if (this.Subject != null && this.Subject.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Subject, length must be less than 255.", new[] { "Subject" }); - } - - // Title (string) maxLength - if (this.Title != null && this.Title.Length > 255) - { - yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Title, length must be less than 255.", new[] { "Title" }); - } - - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/SubFile.cs b/sdks/dotnet/src/Dropbox.Sign/Model/SubFile.cs deleted file mode 100644 index d17056299..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/SubFile.cs +++ /dev/null @@ -1,167 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// Actual uploaded physical file - /// - [DataContract(Name = "SubFile")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class SubFile : IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected SubFile() { } - /// - /// Initializes a new instance of the class. - /// - /// Actual physical uploaded file name that is derived during upload. Not settable parameter. (default to ""). - public SubFile(string name = @"") - { - - // use default value if no "name" provided - this.Name = name ?? ""; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static SubFile Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of SubFile"); - } - - return obj; - } - - /// - /// Actual physical uploaded file name that is derived during upload. Not settable parameter. - /// - /// Actual physical uploaded file name that is derived during upload. Not settable parameter. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class SubFile {\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as SubFile); - } - - /// - /// Returns true if SubFile instances are equal - /// - /// Instance of SubFile to be compared - /// Boolean - public bool Equals(SubFile input) - { - if (input == null) - { - return false; - } - return - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - return hashCode; - } - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - IEnumerable IValidatableObject.Validate(ValidationContext validationContext) - { - yield break; - } - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - - return types; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseCustomField.cs b/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseCustomField.cs deleted file mode 100644 index 39e50fb91..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseCustomField.cs +++ /dev/null @@ -1,475 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// TemplateResponseCustomField - /// - [DataContract(Name = "TemplateResponseCustomField")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class TemplateResponseCustomField : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - [JsonConverter(typeof(StringEnumConverter))] - public enum TypeEnum - { - /// - /// Enum Text for value: text - /// - [EnumMember(Value = "text")] - Text = 1, - - /// - /// Enum Checkbox for value: checkbox - /// - [EnumMember(Value = "checkbox")] - Checkbox = 2 - - } - - - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - [DataMember(Name = "type", EmitDefaultValue = true)] - public TypeEnum? Type { get; set; } - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected TemplateResponseCustomField() { } - /// - /// Initializes a new instance of the class. - /// - /// The name of the Custom Field.. - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported.. - /// The horizontal offset in pixels for this form field.. - /// The vertical offset in pixels for this form field.. - /// The width in pixels of this form field.. - /// The height in pixels of this form field.. - /// Boolean showing whether or not this field is required.. - /// The unique ID for this field.. - /// The name of the group this field is in. If this field is not a group, this defaults to `null`.. - /// avgTextLength. - /// Whether this form field is multiline text.. - /// Original font size used in this form field's text.. - /// Font family used in this form field's text.. - public TemplateResponseCustomField(string name = default(string), TypeEnum? type = default(TypeEnum?), int x = default(int), int y = default(int), int width = default(int), int height = default(int), bool required = default(bool), string apiId = default(string), string group = default(string), TemplateResponseFieldAvgTextLength avgTextLength = default(TemplateResponseFieldAvgTextLength), bool? isMultiline = default(bool?), int? originalFontSize = default(int?), string fontFamily = default(string)) - { - - this.Name = name; - this.Type = type; - this.X = x; - this.Y = y; - this.Width = width; - this.Height = height; - this.Required = required; - this.ApiId = apiId; - this.Group = group; - this.AvgTextLength = avgTextLength; - this.IsMultiline = isMultiline; - this.OriginalFontSize = originalFontSize; - this.FontFamily = fontFamily; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static TemplateResponseCustomField Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of TemplateResponseCustomField"); - } - - return obj; - } - - /// - /// The name of the Custom Field. - /// - /// The name of the Custom Field. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// The horizontal offset in pixels for this form field. - /// - /// The horizontal offset in pixels for this form field. - [DataMember(Name = "x", EmitDefaultValue = true)] - public int X { get; set; } - - /// - /// The vertical offset in pixels for this form field. - /// - /// The vertical offset in pixels for this form field. - [DataMember(Name = "y", EmitDefaultValue = true)] - public int Y { get; set; } - - /// - /// The width in pixels of this form field. - /// - /// The width in pixels of this form field. - [DataMember(Name = "width", EmitDefaultValue = true)] - public int Width { get; set; } - - /// - /// The height in pixels of this form field. - /// - /// The height in pixels of this form field. - [DataMember(Name = "height", EmitDefaultValue = true)] - public int Height { get; set; } - - /// - /// Boolean showing whether or not this field is required. - /// - /// Boolean showing whether or not this field is required. - [DataMember(Name = "required", EmitDefaultValue = true)] - public bool Required { get; set; } - - /// - /// The unique ID for this field. - /// - /// The unique ID for this field. - [DataMember(Name = "api_id", EmitDefaultValue = true)] - public string ApiId { get; set; } - - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - [DataMember(Name = "group", EmitDefaultValue = true)] - public string Group { get; set; } - - /// - /// Gets or Sets AvgTextLength - /// - [DataMember(Name = "avg_text_length", EmitDefaultValue = true)] - public TemplateResponseFieldAvgTextLength AvgTextLength { get; set; } - - /// - /// Whether this form field is multiline text. - /// - /// Whether this form field is multiline text. - [DataMember(Name = "isMultiline", EmitDefaultValue = true)] - public bool? IsMultiline { get; set; } - - /// - /// Original font size used in this form field's text. - /// - /// Original font size used in this form field's text. - [DataMember(Name = "originalFontSize", EmitDefaultValue = true)] - public int? OriginalFontSize { get; set; } - - /// - /// Font family used in this form field's text. - /// - /// Font family used in this form field's text. - [DataMember(Name = "fontFamily", EmitDefaultValue = true)] - public string FontFamily { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class TemplateResponseCustomField {\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append(" Type: ").Append(Type).Append("\n"); - sb.Append(" X: ").Append(X).Append("\n"); - sb.Append(" Y: ").Append(Y).Append("\n"); - sb.Append(" Width: ").Append(Width).Append("\n"); - sb.Append(" Height: ").Append(Height).Append("\n"); - sb.Append(" Required: ").Append(Required).Append("\n"); - sb.Append(" ApiId: ").Append(ApiId).Append("\n"); - sb.Append(" Group: ").Append(Group).Append("\n"); - sb.Append(" AvgTextLength: ").Append(AvgTextLength).Append("\n"); - sb.Append(" IsMultiline: ").Append(IsMultiline).Append("\n"); - sb.Append(" OriginalFontSize: ").Append(OriginalFontSize).Append("\n"); - sb.Append(" FontFamily: ").Append(FontFamily).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as TemplateResponseCustomField); - } - - /// - /// Returns true if TemplateResponseCustomField instances are equal - /// - /// Instance of TemplateResponseCustomField to be compared - /// Boolean - public bool Equals(TemplateResponseCustomField input) - { - if (input == null) - { - return false; - } - return - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ) && - ( - this.Type == input.Type || - this.Type.Equals(input.Type) - ) && - ( - this.X == input.X || - this.X.Equals(input.X) - ) && - ( - this.Y == input.Y || - this.Y.Equals(input.Y) - ) && - ( - this.Width == input.Width || - this.Width.Equals(input.Width) - ) && - ( - this.Height == input.Height || - this.Height.Equals(input.Height) - ) && - ( - this.Required == input.Required || - this.Required.Equals(input.Required) - ) && - ( - this.ApiId == input.ApiId || - (this.ApiId != null && - this.ApiId.Equals(input.ApiId)) - ) && - ( - this.Group == input.Group || - (this.Group != null && - this.Group.Equals(input.Group)) - ) && - ( - this.AvgTextLength == input.AvgTextLength || - (this.AvgTextLength != null && - this.AvgTextLength.Equals(input.AvgTextLength)) - ) && - ( - this.IsMultiline == input.IsMultiline || - (this.IsMultiline != null && - this.IsMultiline.Equals(input.IsMultiline)) - ) && - ( - this.OriginalFontSize == input.OriginalFontSize || - (this.OriginalFontSize != null && - this.OriginalFontSize.Equals(input.OriginalFontSize)) - ) && - ( - this.FontFamily == input.FontFamily || - (this.FontFamily != null && - this.FontFamily.Equals(input.FontFamily)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - hashCode = (hashCode * 59) + this.Type.GetHashCode(); - hashCode = (hashCode * 59) + this.X.GetHashCode(); - hashCode = (hashCode * 59) + this.Y.GetHashCode(); - hashCode = (hashCode * 59) + this.Width.GetHashCode(); - hashCode = (hashCode * 59) + this.Height.GetHashCode(); - hashCode = (hashCode * 59) + this.Required.GetHashCode(); - if (this.ApiId != null) - { - hashCode = (hashCode * 59) + this.ApiId.GetHashCode(); - } - if (this.Group != null) - { - hashCode = (hashCode * 59) + this.Group.GetHashCode(); - } - if (this.AvgTextLength != null) - { - hashCode = (hashCode * 59) + this.AvgTextLength.GetHashCode(); - } - if (this.IsMultiline != null) - { - hashCode = (hashCode * 59) + this.IsMultiline.GetHashCode(); - } - if (this.OriginalFontSize != null) - { - hashCode = (hashCode * 59) + this.OriginalFontSize.GetHashCode(); - } - if (this.FontFamily != null) - { - hashCode = (hashCode * 59) + this.FontFamily.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - types.Add(new OpenApiType() - { - Name = "type", - Property = "Type", - Type = "string", - Value = Type, - }); - types.Add(new OpenApiType() - { - Name = "x", - Property = "X", - Type = "int", - Value = X, - }); - types.Add(new OpenApiType() - { - Name = "y", - Property = "Y", - Type = "int", - Value = Y, - }); - types.Add(new OpenApiType() - { - Name = "width", - Property = "Width", - Type = "int", - Value = Width, - }); - types.Add(new OpenApiType() - { - Name = "height", - Property = "Height", - Type = "int", - Value = Height, - }); - types.Add(new OpenApiType() - { - Name = "required", - Property = "Required", - Type = "bool", - Value = Required, - }); - types.Add(new OpenApiType() - { - Name = "api_id", - Property = "ApiId", - Type = "string", - Value = ApiId, - }); - types.Add(new OpenApiType() - { - Name = "group", - Property = "Group", - Type = "string", - Value = Group, - }); - types.Add(new OpenApiType() - { - Name = "avg_text_length", - Property = "AvgTextLength", - Type = "TemplateResponseFieldAvgTextLength", - Value = AvgTextLength, - }); - types.Add(new OpenApiType() - { - Name = "isMultiline", - Property = "IsMultiline", - Type = "bool?", - Value = IsMultiline, - }); - types.Add(new OpenApiType() - { - Name = "originalFontSize", - Property = "OriginalFontSize", - Type = "int?", - Value = OriginalFontSize, - }); - types.Add(new OpenApiType() - { - Name = "fontFamily", - Property = "FontFamily", - Type = "string", - Value = FontFamily, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentCustomField.cs b/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentCustomField.cs deleted file mode 100644 index 958f7595b..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentCustomField.cs +++ /dev/null @@ -1,554 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// TemplateResponseDocumentCustomField - /// - [DataContract(Name = "TemplateResponseDocumentCustomField")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class TemplateResponseDocumentCustomField : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - [JsonConverter(typeof(StringEnumConverter))] - public enum TypeEnum - { - /// - /// Enum Text for value: text - /// - [EnumMember(Value = "text")] - Text = 1, - - /// - /// Enum Checkbox for value: checkbox - /// - [EnumMember(Value = "checkbox")] - Checkbox = 2 - - } - - - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - /// - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported. - [DataMember(Name = "type", EmitDefaultValue = true)] - public TypeEnum? Type { get; set; } - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected TemplateResponseDocumentCustomField() { } - /// - /// Initializes a new instance of the class. - /// - /// The name of the Custom Field.. - /// The type of this Custom Field. Only `text` and `checkbox` are currently supported.. - /// The signer of the Custom Field.. - /// The horizontal offset in pixels for this form field.. - /// The vertical offset in pixels for this form field.. - /// The width in pixels of this form field.. - /// The height in pixels of this form field.. - /// Boolean showing whether or not this field is required.. - /// The unique ID for this field.. - /// The name of the group this field is in. If this field is not a group, this defaults to `null`.. - /// avgTextLength. - /// Whether this form field is multiline text.. - /// Original font size used in this form field's text.. - /// Font family used in this form field's text.. - /// Deprecated. Use `form_fields` inside the [documents](https://developers.hellosign.com/api/reference/operation/templateGet/#!c=200&path=template/documents&t=response) array instead.. - /// reusableFormId. - public TemplateResponseDocumentCustomField(string name = default(string), TypeEnum? type = default(TypeEnum?), string signer = default(string), int x = default(int), int y = default(int), int width = default(int), int height = default(int), bool required = default(bool), string apiId = default(string), string group = default(string), TemplateResponseFieldAvgTextLength avgTextLength = default(TemplateResponseFieldAvgTextLength), bool? isMultiline = default(bool?), int? originalFontSize = default(int?), string fontFamily = default(string), Object namedFormFields = default(Object), string reusableFormId = default(string)) - { - - this.Name = name; - this.Type = type; - this.Signer = signer; - this.X = x; - this.Y = y; - this.Width = width; - this.Height = height; - this.Required = required; - this.ApiId = apiId; - this.Group = group; - this.AvgTextLength = avgTextLength; - this.IsMultiline = isMultiline; - this.OriginalFontSize = originalFontSize; - this.FontFamily = fontFamily; - this.NamedFormFields = namedFormFields; - this.ReusableFormId = reusableFormId; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static TemplateResponseDocumentCustomField Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of TemplateResponseDocumentCustomField"); - } - - return obj; - } - - /// - /// The name of the Custom Field. - /// - /// The name of the Custom Field. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// The signer of the Custom Field. - /// - /// The signer of the Custom Field. - [DataMember(Name = "signer", EmitDefaultValue = true)] - public string Signer { get; set; } - - /// - /// The horizontal offset in pixels for this form field. - /// - /// The horizontal offset in pixels for this form field. - [DataMember(Name = "x", EmitDefaultValue = true)] - public int X { get; set; } - - /// - /// The vertical offset in pixels for this form field. - /// - /// The vertical offset in pixels for this form field. - [DataMember(Name = "y", EmitDefaultValue = true)] - public int Y { get; set; } - - /// - /// The width in pixels of this form field. - /// - /// The width in pixels of this form field. - [DataMember(Name = "width", EmitDefaultValue = true)] - public int Width { get; set; } - - /// - /// The height in pixels of this form field. - /// - /// The height in pixels of this form field. - [DataMember(Name = "height", EmitDefaultValue = true)] - public int Height { get; set; } - - /// - /// Boolean showing whether or not this field is required. - /// - /// Boolean showing whether or not this field is required. - [DataMember(Name = "required", EmitDefaultValue = true)] - public bool Required { get; set; } - - /// - /// The unique ID for this field. - /// - /// The unique ID for this field. - [DataMember(Name = "api_id", EmitDefaultValue = true)] - public string ApiId { get; set; } - - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - [DataMember(Name = "group", EmitDefaultValue = true)] - public string Group { get; set; } - - /// - /// Gets or Sets AvgTextLength - /// - [DataMember(Name = "avg_text_length", EmitDefaultValue = true)] - public TemplateResponseFieldAvgTextLength AvgTextLength { get; set; } - - /// - /// Whether this form field is multiline text. - /// - /// Whether this form field is multiline text. - [DataMember(Name = "isMultiline", EmitDefaultValue = true)] - public bool? IsMultiline { get; set; } - - /// - /// Original font size used in this form field's text. - /// - /// Original font size used in this form field's text. - [DataMember(Name = "originalFontSize", EmitDefaultValue = true)] - public int? OriginalFontSize { get; set; } - - /// - /// Font family used in this form field's text. - /// - /// Font family used in this form field's text. - [DataMember(Name = "fontFamily", EmitDefaultValue = true)] - public string FontFamily { get; set; } - - /// - /// Deprecated. Use `form_fields` inside the [documents](https://developers.hellosign.com/api/reference/operation/templateGet/#!c=200&path=template/documents&t=response) array instead. - /// - /// Deprecated. Use `form_fields` inside the [documents](https://developers.hellosign.com/api/reference/operation/templateGet/#!c=200&path=template/documents&t=response) array instead. - [DataMember(Name = "named_form_fields", EmitDefaultValue = true)] - [Obsolete] - public Object NamedFormFields { get; set; } - - /// - /// Gets or Sets ReusableFormId - /// - [DataMember(Name = "reusable_form_id", EmitDefaultValue = true)] - [Obsolete] - public string ReusableFormId { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class TemplateResponseDocumentCustomField {\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append(" Type: ").Append(Type).Append("\n"); - sb.Append(" Signer: ").Append(Signer).Append("\n"); - sb.Append(" X: ").Append(X).Append("\n"); - sb.Append(" Y: ").Append(Y).Append("\n"); - sb.Append(" Width: ").Append(Width).Append("\n"); - sb.Append(" Height: ").Append(Height).Append("\n"); - sb.Append(" Required: ").Append(Required).Append("\n"); - sb.Append(" ApiId: ").Append(ApiId).Append("\n"); - sb.Append(" Group: ").Append(Group).Append("\n"); - sb.Append(" AvgTextLength: ").Append(AvgTextLength).Append("\n"); - sb.Append(" IsMultiline: ").Append(IsMultiline).Append("\n"); - sb.Append(" OriginalFontSize: ").Append(OriginalFontSize).Append("\n"); - sb.Append(" FontFamily: ").Append(FontFamily).Append("\n"); - sb.Append(" NamedFormFields: ").Append(NamedFormFields).Append("\n"); - sb.Append(" ReusableFormId: ").Append(ReusableFormId).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as TemplateResponseDocumentCustomField); - } - - /// - /// Returns true if TemplateResponseDocumentCustomField instances are equal - /// - /// Instance of TemplateResponseDocumentCustomField to be compared - /// Boolean - public bool Equals(TemplateResponseDocumentCustomField input) - { - if (input == null) - { - return false; - } - return - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ) && - ( - this.Type == input.Type || - this.Type.Equals(input.Type) - ) && - ( - this.Signer == input.Signer || - (this.Signer != null && - this.Signer.Equals(input.Signer)) - ) && - ( - this.X == input.X || - this.X.Equals(input.X) - ) && - ( - this.Y == input.Y || - this.Y.Equals(input.Y) - ) && - ( - this.Width == input.Width || - this.Width.Equals(input.Width) - ) && - ( - this.Height == input.Height || - this.Height.Equals(input.Height) - ) && - ( - this.Required == input.Required || - this.Required.Equals(input.Required) - ) && - ( - this.ApiId == input.ApiId || - (this.ApiId != null && - this.ApiId.Equals(input.ApiId)) - ) && - ( - this.Group == input.Group || - (this.Group != null && - this.Group.Equals(input.Group)) - ) && - ( - this.AvgTextLength == input.AvgTextLength || - (this.AvgTextLength != null && - this.AvgTextLength.Equals(input.AvgTextLength)) - ) && - ( - this.IsMultiline == input.IsMultiline || - (this.IsMultiline != null && - this.IsMultiline.Equals(input.IsMultiline)) - ) && - ( - this.OriginalFontSize == input.OriginalFontSize || - (this.OriginalFontSize != null && - this.OriginalFontSize.Equals(input.OriginalFontSize)) - ) && - ( - this.FontFamily == input.FontFamily || - (this.FontFamily != null && - this.FontFamily.Equals(input.FontFamily)) - ) && - ( - this.NamedFormFields == input.NamedFormFields || - (this.NamedFormFields != null && - this.NamedFormFields.Equals(input.NamedFormFields)) - ) && - ( - this.ReusableFormId == input.ReusableFormId || - (this.ReusableFormId != null && - this.ReusableFormId.Equals(input.ReusableFormId)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - hashCode = (hashCode * 59) + this.Type.GetHashCode(); - if (this.Signer != null) - { - hashCode = (hashCode * 59) + this.Signer.GetHashCode(); - } - hashCode = (hashCode * 59) + this.X.GetHashCode(); - hashCode = (hashCode * 59) + this.Y.GetHashCode(); - hashCode = (hashCode * 59) + this.Width.GetHashCode(); - hashCode = (hashCode * 59) + this.Height.GetHashCode(); - hashCode = (hashCode * 59) + this.Required.GetHashCode(); - if (this.ApiId != null) - { - hashCode = (hashCode * 59) + this.ApiId.GetHashCode(); - } - if (this.Group != null) - { - hashCode = (hashCode * 59) + this.Group.GetHashCode(); - } - if (this.AvgTextLength != null) - { - hashCode = (hashCode * 59) + this.AvgTextLength.GetHashCode(); - } - if (this.IsMultiline != null) - { - hashCode = (hashCode * 59) + this.IsMultiline.GetHashCode(); - } - if (this.OriginalFontSize != null) - { - hashCode = (hashCode * 59) + this.OriginalFontSize.GetHashCode(); - } - if (this.FontFamily != null) - { - hashCode = (hashCode * 59) + this.FontFamily.GetHashCode(); - } - if (this.NamedFormFields != null) - { - hashCode = (hashCode * 59) + this.NamedFormFields.GetHashCode(); - } - if (this.ReusableFormId != null) - { - hashCode = (hashCode * 59) + this.ReusableFormId.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - types.Add(new OpenApiType() - { - Name = "type", - Property = "Type", - Type = "string", - Value = Type, - }); - types.Add(new OpenApiType() - { - Name = "signer", - Property = "Signer", - Type = "string", - Value = Signer, - }); - types.Add(new OpenApiType() - { - Name = "x", - Property = "X", - Type = "int", - Value = X, - }); - types.Add(new OpenApiType() - { - Name = "y", - Property = "Y", - Type = "int", - Value = Y, - }); - types.Add(new OpenApiType() - { - Name = "width", - Property = "Width", - Type = "int", - Value = Width, - }); - types.Add(new OpenApiType() - { - Name = "height", - Property = "Height", - Type = "int", - Value = Height, - }); - types.Add(new OpenApiType() - { - Name = "required", - Property = "Required", - Type = "bool", - Value = Required, - }); - types.Add(new OpenApiType() - { - Name = "api_id", - Property = "ApiId", - Type = "string", - Value = ApiId, - }); - types.Add(new OpenApiType() - { - Name = "group", - Property = "Group", - Type = "string", - Value = Group, - }); - types.Add(new OpenApiType() - { - Name = "avg_text_length", - Property = "AvgTextLength", - Type = "TemplateResponseFieldAvgTextLength", - Value = AvgTextLength, - }); - types.Add(new OpenApiType() - { - Name = "isMultiline", - Property = "IsMultiline", - Type = "bool?", - Value = IsMultiline, - }); - types.Add(new OpenApiType() - { - Name = "originalFontSize", - Property = "OriginalFontSize", - Type = "int?", - Value = OriginalFontSize, - }); - types.Add(new OpenApiType() - { - Name = "fontFamily", - Property = "FontFamily", - Type = "string", - Value = FontFamily, - }); - types.Add(new OpenApiType() - { - Name = "named_form_fields", - Property = "NamedFormFields", - Type = "Object", - Value = NamedFormFields, - }); - types.Add(new OpenApiType() - { - Name = "reusable_form_id", - Property = "ReusableFormId", - Type = "string", - Value = ReusableFormId, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentFormField.cs b/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentFormField.cs deleted file mode 100644 index 9a84275b0..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentFormField.cs +++ /dev/null @@ -1,549 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// TemplateResponseDocumentFormField - /// - [DataContract(Name = "TemplateResponseDocumentFormField")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class TemplateResponseDocumentFormField : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// The type of this form field. See [field types](/api/reference/constants/#field-types). - /// - /// The type of this form field. See [field types](/api/reference/constants/#field-types). - [JsonConverter(typeof(StringEnumConverter))] - public enum TypeEnum - { - /// - /// Enum Checkbox for value: checkbox - /// - [EnumMember(Value = "checkbox")] - Checkbox = 1, - - /// - /// Enum CheckboxMerge for value: checkbox-merge - /// - [EnumMember(Value = "checkbox-merge")] - CheckboxMerge = 2, - - /// - /// Enum DateSigned for value: date_signed - /// - [EnumMember(Value = "date_signed")] - DateSigned = 3, - - /// - /// Enum Dropdown for value: dropdown - /// - [EnumMember(Value = "dropdown")] - Dropdown = 4, - - /// - /// Enum Hyperlink for value: hyperlink - /// - [EnumMember(Value = "hyperlink")] - Hyperlink = 5, - - /// - /// Enum Initials for value: initials - /// - [EnumMember(Value = "initials")] - Initials = 6, - - /// - /// Enum Signature for value: signature - /// - [EnumMember(Value = "signature")] - Signature = 7, - - /// - /// Enum Radio for value: radio - /// - [EnumMember(Value = "radio")] - Radio = 8, - - /// - /// Enum Text for value: text - /// - [EnumMember(Value = "text")] - Text = 9, - - /// - /// Enum TextMerge for value: text-merge - /// - [EnumMember(Value = "text-merge")] - TextMerge = 10 - - } - - - /// - /// The type of this form field. See [field types](/api/reference/constants/#field-types). - /// - /// The type of this form field. See [field types](/api/reference/constants/#field-types). - [DataMember(Name = "type", EmitDefaultValue = true)] - public TypeEnum? Type { get; set; } - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected TemplateResponseDocumentFormField() { } - /// - /// Initializes a new instance of the class. - /// - /// A unique id for the form field.. - /// The name of the form field.. - /// The type of this form field. See [field types](/api/reference/constants/#field-types).. - /// The signer of the Form Field.. - /// The horizontal offset in pixels for this form field.. - /// The vertical offset in pixels for this form field.. - /// The width in pixels of this form field.. - /// The height in pixels of this form field.. - /// Boolean showing whether or not this field is required.. - /// The name of the group this field is in. If this field is not a group, this defaults to `null`.. - /// avgTextLength. - /// Whether this form field is multiline text.. - /// Original font size used in this form field's text.. - /// Font family used in this form field's text.. - public TemplateResponseDocumentFormField(string apiId = default(string), string name = default(string), TypeEnum? type = default(TypeEnum?), string signer = default(string), int x = default(int), int y = default(int), int width = default(int), int height = default(int), bool required = default(bool), string group = default(string), TemplateResponseFieldAvgTextLength avgTextLength = default(TemplateResponseFieldAvgTextLength), bool? isMultiline = default(bool?), int? originalFontSize = default(int?), string fontFamily = default(string)) - { - - this.ApiId = apiId; - this.Name = name; - this.Type = type; - this.Signer = signer; - this.X = x; - this.Y = y; - this.Width = width; - this.Height = height; - this.Required = required; - this.Group = group; - this.AvgTextLength = avgTextLength; - this.IsMultiline = isMultiline; - this.OriginalFontSize = originalFontSize; - this.FontFamily = fontFamily; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static TemplateResponseDocumentFormField Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of TemplateResponseDocumentFormField"); - } - - return obj; - } - - /// - /// A unique id for the form field. - /// - /// A unique id for the form field. - [DataMember(Name = "api_id", EmitDefaultValue = true)] - public string ApiId { get; set; } - - /// - /// The name of the form field. - /// - /// The name of the form field. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// The signer of the Form Field. - /// - /// The signer of the Form Field. - [DataMember(Name = "signer", EmitDefaultValue = true)] - public string Signer { get; set; } - - /// - /// The horizontal offset in pixels for this form field. - /// - /// The horizontal offset in pixels for this form field. - [DataMember(Name = "x", EmitDefaultValue = true)] - public int X { get; set; } - - /// - /// The vertical offset in pixels for this form field. - /// - /// The vertical offset in pixels for this form field. - [DataMember(Name = "y", EmitDefaultValue = true)] - public int Y { get; set; } - - /// - /// The width in pixels of this form field. - /// - /// The width in pixels of this form field. - [DataMember(Name = "width", EmitDefaultValue = true)] - public int Width { get; set; } - - /// - /// The height in pixels of this form field. - /// - /// The height in pixels of this form field. - [DataMember(Name = "height", EmitDefaultValue = true)] - public int Height { get; set; } - - /// - /// Boolean showing whether or not this field is required. - /// - /// Boolean showing whether or not this field is required. - [DataMember(Name = "required", EmitDefaultValue = true)] - public bool Required { get; set; } - - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - [DataMember(Name = "group", EmitDefaultValue = true)] - public string Group { get; set; } - - /// - /// Gets or Sets AvgTextLength - /// - [DataMember(Name = "avg_text_length", EmitDefaultValue = true)] - public TemplateResponseFieldAvgTextLength AvgTextLength { get; set; } - - /// - /// Whether this form field is multiline text. - /// - /// Whether this form field is multiline text. - [DataMember(Name = "isMultiline", EmitDefaultValue = true)] - public bool? IsMultiline { get; set; } - - /// - /// Original font size used in this form field's text. - /// - /// Original font size used in this form field's text. - [DataMember(Name = "originalFontSize", EmitDefaultValue = true)] - public int? OriginalFontSize { get; set; } - - /// - /// Font family used in this form field's text. - /// - /// Font family used in this form field's text. - [DataMember(Name = "fontFamily", EmitDefaultValue = true)] - public string FontFamily { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class TemplateResponseDocumentFormField {\n"); - sb.Append(" ApiId: ").Append(ApiId).Append("\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append(" Type: ").Append(Type).Append("\n"); - sb.Append(" Signer: ").Append(Signer).Append("\n"); - sb.Append(" X: ").Append(X).Append("\n"); - sb.Append(" Y: ").Append(Y).Append("\n"); - sb.Append(" Width: ").Append(Width).Append("\n"); - sb.Append(" Height: ").Append(Height).Append("\n"); - sb.Append(" Required: ").Append(Required).Append("\n"); - sb.Append(" Group: ").Append(Group).Append("\n"); - sb.Append(" AvgTextLength: ").Append(AvgTextLength).Append("\n"); - sb.Append(" IsMultiline: ").Append(IsMultiline).Append("\n"); - sb.Append(" OriginalFontSize: ").Append(OriginalFontSize).Append("\n"); - sb.Append(" FontFamily: ").Append(FontFamily).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as TemplateResponseDocumentFormField); - } - - /// - /// Returns true if TemplateResponseDocumentFormField instances are equal - /// - /// Instance of TemplateResponseDocumentFormField to be compared - /// Boolean - public bool Equals(TemplateResponseDocumentFormField input) - { - if (input == null) - { - return false; - } - return - ( - this.ApiId == input.ApiId || - (this.ApiId != null && - this.ApiId.Equals(input.ApiId)) - ) && - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ) && - ( - this.Type == input.Type || - this.Type.Equals(input.Type) - ) && - ( - this.Signer == input.Signer || - (this.Signer != null && - this.Signer.Equals(input.Signer)) - ) && - ( - this.X == input.X || - this.X.Equals(input.X) - ) && - ( - this.Y == input.Y || - this.Y.Equals(input.Y) - ) && - ( - this.Width == input.Width || - this.Width.Equals(input.Width) - ) && - ( - this.Height == input.Height || - this.Height.Equals(input.Height) - ) && - ( - this.Required == input.Required || - this.Required.Equals(input.Required) - ) && - ( - this.Group == input.Group || - (this.Group != null && - this.Group.Equals(input.Group)) - ) && - ( - this.AvgTextLength == input.AvgTextLength || - (this.AvgTextLength != null && - this.AvgTextLength.Equals(input.AvgTextLength)) - ) && - ( - this.IsMultiline == input.IsMultiline || - (this.IsMultiline != null && - this.IsMultiline.Equals(input.IsMultiline)) - ) && - ( - this.OriginalFontSize == input.OriginalFontSize || - (this.OriginalFontSize != null && - this.OriginalFontSize.Equals(input.OriginalFontSize)) - ) && - ( - this.FontFamily == input.FontFamily || - (this.FontFamily != null && - this.FontFamily.Equals(input.FontFamily)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.ApiId != null) - { - hashCode = (hashCode * 59) + this.ApiId.GetHashCode(); - } - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - hashCode = (hashCode * 59) + this.Type.GetHashCode(); - if (this.Signer != null) - { - hashCode = (hashCode * 59) + this.Signer.GetHashCode(); - } - hashCode = (hashCode * 59) + this.X.GetHashCode(); - hashCode = (hashCode * 59) + this.Y.GetHashCode(); - hashCode = (hashCode * 59) + this.Width.GetHashCode(); - hashCode = (hashCode * 59) + this.Height.GetHashCode(); - hashCode = (hashCode * 59) + this.Required.GetHashCode(); - if (this.Group != null) - { - hashCode = (hashCode * 59) + this.Group.GetHashCode(); - } - if (this.AvgTextLength != null) - { - hashCode = (hashCode * 59) + this.AvgTextLength.GetHashCode(); - } - if (this.IsMultiline != null) - { - hashCode = (hashCode * 59) + this.IsMultiline.GetHashCode(); - } - if (this.OriginalFontSize != null) - { - hashCode = (hashCode * 59) + this.OriginalFontSize.GetHashCode(); - } - if (this.FontFamily != null) - { - hashCode = (hashCode * 59) + this.FontFamily.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "api_id", - Property = "ApiId", - Type = "string", - Value = ApiId, - }); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - types.Add(new OpenApiType() - { - Name = "type", - Property = "Type", - Type = "string", - Value = Type, - }); - types.Add(new OpenApiType() - { - Name = "signer", - Property = "Signer", - Type = "string", - Value = Signer, - }); - types.Add(new OpenApiType() - { - Name = "x", - Property = "X", - Type = "int", - Value = X, - }); - types.Add(new OpenApiType() - { - Name = "y", - Property = "Y", - Type = "int", - Value = Y, - }); - types.Add(new OpenApiType() - { - Name = "width", - Property = "Width", - Type = "int", - Value = Width, - }); - types.Add(new OpenApiType() - { - Name = "height", - Property = "Height", - Type = "int", - Value = Height, - }); - types.Add(new OpenApiType() - { - Name = "required", - Property = "Required", - Type = "bool", - Value = Required, - }); - types.Add(new OpenApiType() - { - Name = "group", - Property = "Group", - Type = "string", - Value = Group, - }); - types.Add(new OpenApiType() - { - Name = "avg_text_length", - Property = "AvgTextLength", - Type = "TemplateResponseFieldAvgTextLength", - Value = AvgTextLength, - }); - types.Add(new OpenApiType() - { - Name = "isMultiline", - Property = "IsMultiline", - Type = "bool?", - Value = IsMultiline, - }); - types.Add(new OpenApiType() - { - Name = "originalFontSize", - Property = "OriginalFontSize", - Type = "int?", - Value = OriginalFontSize, - }); - types.Add(new OpenApiType() - { - Name = "fontFamily", - Property = "FontFamily", - Type = "string", - Value = FontFamily, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentStaticField.cs b/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentStaticField.cs deleted file mode 100644 index 85f472c5b..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseDocumentStaticField.cs +++ /dev/null @@ -1,381 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// TemplateResponseDocumentStaticField - /// - [DataContract(Name = "TemplateResponseDocumentStaticField")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class TemplateResponseDocumentStaticField : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected TemplateResponseDocumentStaticField() { } - /// - /// Initializes a new instance of the class. - /// - /// The name of the static field.. - /// The type of this static field. See [field types](/api/reference/constants/#field-types).. - /// The signer of the Static Field.. - /// The horizontal offset in pixels for this static field.. - /// The vertical offset in pixels for this static field.. - /// The width in pixels of this static field.. - /// The height in pixels of this static field.. - /// Boolean showing whether or not this field is required.. - /// A unique id for the static field.. - /// The name of the group this field is in. If this field is not a group, this defaults to `null`.. - public TemplateResponseDocumentStaticField(string name = default(string), string type = default(string), string signer = default(string), int x = default(int), int y = default(int), int width = default(int), int height = default(int), bool required = default(bool), string apiId = default(string), string group = default(string)) - { - - this.Name = name; - this.Type = type; - this.Signer = signer; - this.X = x; - this.Y = y; - this.Width = width; - this.Height = height; - this.Required = required; - this.ApiId = apiId; - this.Group = group; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static TemplateResponseDocumentStaticField Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of TemplateResponseDocumentStaticField"); - } - - return obj; - } - - /// - /// The name of the static field. - /// - /// The name of the static field. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// The type of this static field. See [field types](/api/reference/constants/#field-types). - /// - /// The type of this static field. See [field types](/api/reference/constants/#field-types). - [DataMember(Name = "type", EmitDefaultValue = true)] - public string Type { get; set; } - - /// - /// The signer of the Static Field. - /// - /// The signer of the Static Field. - [DataMember(Name = "signer", EmitDefaultValue = true)] - public string Signer { get; set; } - - /// - /// The horizontal offset in pixels for this static field. - /// - /// The horizontal offset in pixels for this static field. - [DataMember(Name = "x", EmitDefaultValue = true)] - public int X { get; set; } - - /// - /// The vertical offset in pixels for this static field. - /// - /// The vertical offset in pixels for this static field. - [DataMember(Name = "y", EmitDefaultValue = true)] - public int Y { get; set; } - - /// - /// The width in pixels of this static field. - /// - /// The width in pixels of this static field. - [DataMember(Name = "width", EmitDefaultValue = true)] - public int Width { get; set; } - - /// - /// The height in pixels of this static field. - /// - /// The height in pixels of this static field. - [DataMember(Name = "height", EmitDefaultValue = true)] - public int Height { get; set; } - - /// - /// Boolean showing whether or not this field is required. - /// - /// Boolean showing whether or not this field is required. - [DataMember(Name = "required", EmitDefaultValue = true)] - public bool Required { get; set; } - - /// - /// A unique id for the static field. - /// - /// A unique id for the static field. - [DataMember(Name = "api_id", EmitDefaultValue = true)] - public string ApiId { get; set; } - - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - [DataMember(Name = "group", EmitDefaultValue = true)] - public string Group { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class TemplateResponseDocumentStaticField {\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append(" Type: ").Append(Type).Append("\n"); - sb.Append(" Signer: ").Append(Signer).Append("\n"); - sb.Append(" X: ").Append(X).Append("\n"); - sb.Append(" Y: ").Append(Y).Append("\n"); - sb.Append(" Width: ").Append(Width).Append("\n"); - sb.Append(" Height: ").Append(Height).Append("\n"); - sb.Append(" Required: ").Append(Required).Append("\n"); - sb.Append(" ApiId: ").Append(ApiId).Append("\n"); - sb.Append(" Group: ").Append(Group).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as TemplateResponseDocumentStaticField); - } - - /// - /// Returns true if TemplateResponseDocumentStaticField instances are equal - /// - /// Instance of TemplateResponseDocumentStaticField to be compared - /// Boolean - public bool Equals(TemplateResponseDocumentStaticField input) - { - if (input == null) - { - return false; - } - return - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ) && - ( - this.Type == input.Type || - (this.Type != null && - this.Type.Equals(input.Type)) - ) && - ( - this.Signer == input.Signer || - (this.Signer != null && - this.Signer.Equals(input.Signer)) - ) && - ( - this.X == input.X || - this.X.Equals(input.X) - ) && - ( - this.Y == input.Y || - this.Y.Equals(input.Y) - ) && - ( - this.Width == input.Width || - this.Width.Equals(input.Width) - ) && - ( - this.Height == input.Height || - this.Height.Equals(input.Height) - ) && - ( - this.Required == input.Required || - this.Required.Equals(input.Required) - ) && - ( - this.ApiId == input.ApiId || - (this.ApiId != null && - this.ApiId.Equals(input.ApiId)) - ) && - ( - this.Group == input.Group || - (this.Group != null && - this.Group.Equals(input.Group)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - if (this.Type != null) - { - hashCode = (hashCode * 59) + this.Type.GetHashCode(); - } - if (this.Signer != null) - { - hashCode = (hashCode * 59) + this.Signer.GetHashCode(); - } - hashCode = (hashCode * 59) + this.X.GetHashCode(); - hashCode = (hashCode * 59) + this.Y.GetHashCode(); - hashCode = (hashCode * 59) + this.Width.GetHashCode(); - hashCode = (hashCode * 59) + this.Height.GetHashCode(); - hashCode = (hashCode * 59) + this.Required.GetHashCode(); - if (this.ApiId != null) - { - hashCode = (hashCode * 59) + this.ApiId.GetHashCode(); - } - if (this.Group != null) - { - hashCode = (hashCode * 59) + this.Group.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - types.Add(new OpenApiType() - { - Name = "type", - Property = "Type", - Type = "string", - Value = Type, - }); - types.Add(new OpenApiType() - { - Name = "signer", - Property = "Signer", - Type = "string", - Value = Signer, - }); - types.Add(new OpenApiType() - { - Name = "x", - Property = "X", - Type = "int", - Value = X, - }); - types.Add(new OpenApiType() - { - Name = "y", - Property = "Y", - Type = "int", - Value = Y, - }); - types.Add(new OpenApiType() - { - Name = "width", - Property = "Width", - Type = "int", - Value = Width, - }); - types.Add(new OpenApiType() - { - Name = "height", - Property = "Height", - Type = "int", - Value = Height, - }); - types.Add(new OpenApiType() - { - Name = "required", - Property = "Required", - Type = "bool", - Value = Required, - }); - types.Add(new OpenApiType() - { - Name = "api_id", - Property = "ApiId", - Type = "string", - Value = ApiId, - }); - types.Add(new OpenApiType() - { - Name = "group", - Property = "Group", - Type = "string", - Value = Group, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseNamedFormField.cs b/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseNamedFormField.cs deleted file mode 100644 index d6dfd5f5b..000000000 --- a/sdks/dotnet/src/Dropbox.Sign/Model/TemplateResponseNamedFormField.cs +++ /dev/null @@ -1,484 +0,0 @@ -/* - * Dropbox Sign API - * - * Dropbox Sign v3 API - * - * The version of the OpenAPI document: 3.0.0 - * Contact: apisupport@hellosign.com - * Generated by: https://github.com/openapitools/openapi-generator.git - */ - - -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Linq; -using System.IO; -using System.Runtime.Serialization; -using System.Text; -using System.Text.RegularExpressions; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using Newtonsoft.Json.Linq; -using System.ComponentModel.DataAnnotations; -using OpenAPIDateConverter = Dropbox.Sign.Client.OpenAPIDateConverter; - -namespace Dropbox.Sign.Model -{ - /// - /// TemplateResponseNamedFormField - /// - [DataContract(Name = "TemplateResponseNamedFormField")] - [JsonObject(ItemNullValueHandling = NullValueHandling.Ignore)] - public partial class TemplateResponseNamedFormField : IOpenApiTyped, IEquatable, IValidatableObject - { - /// - /// Initializes a new instance of the class. - /// - [JsonConstructorAttribute] - protected TemplateResponseNamedFormField() { } - /// - /// Initializes a new instance of the class. - /// - /// The name of the Named Form Field.. - /// The type of this Named Form Field. Only `text` and `checkbox` are currently supported.. - /// The signer of the Named Form Field.. - /// The horizontal offset in pixels for this form field.. - /// The vertical offset in pixels for this form field.. - /// The width in pixels of this form field.. - /// The height in pixels of this form field.. - /// Boolean showing whether or not this field is required.. - /// The unique ID for this field.. - /// The name of the group this field is in. If this field is not a group, this defaults to `null`.. - /// avgTextLength. - /// Whether this form field is multiline text.. - /// Original font size used in this form field's text.. - /// Font family used in this form field's text.. - public TemplateResponseNamedFormField(string name = default(string), string type = default(string), string signer = default(string), int x = default(int), int y = default(int), int width = default(int), int height = default(int), bool required = default(bool), string apiId = default(string), string group = default(string), TemplateResponseFieldAvgTextLength avgTextLength = default(TemplateResponseFieldAvgTextLength), bool? isMultiline = default(bool?), int? originalFontSize = default(int?), string fontFamily = default(string)) - { - - this.Name = name; - this.Type = type; - this.Signer = signer; - this.X = x; - this.Y = y; - this.Width = width; - this.Height = height; - this.Required = required; - this.ApiId = apiId; - this.Group = group; - this.AvgTextLength = avgTextLength; - this.IsMultiline = isMultiline; - this.OriginalFontSize = originalFontSize; - this.FontFamily = fontFamily; - } - - /// - /// Attempt to instantiate and hydrate a new instance of this class - /// - /// String of JSON data representing target object - public static TemplateResponseNamedFormField Init(string jsonData) - { - var obj = JsonConvert.DeserializeObject(jsonData); - - if (obj == null) - { - throw new Exception("Unable to deserialize JSON to instance of TemplateResponseNamedFormField"); - } - - return obj; - } - - /// - /// The name of the Named Form Field. - /// - /// The name of the Named Form Field. - [DataMember(Name = "name", EmitDefaultValue = true)] - public string Name { get; set; } - - /// - /// The type of this Named Form Field. Only `text` and `checkbox` are currently supported. - /// - /// The type of this Named Form Field. Only `text` and `checkbox` are currently supported. - [DataMember(Name = "type", EmitDefaultValue = true)] - public string Type { get; set; } - - /// - /// The signer of the Named Form Field. - /// - /// The signer of the Named Form Field. - [DataMember(Name = "signer", EmitDefaultValue = true)] - public string Signer { get; set; } - - /// - /// The horizontal offset in pixels for this form field. - /// - /// The horizontal offset in pixels for this form field. - [DataMember(Name = "x", EmitDefaultValue = true)] - public int X { get; set; } - - /// - /// The vertical offset in pixels for this form field. - /// - /// The vertical offset in pixels for this form field. - [DataMember(Name = "y", EmitDefaultValue = true)] - public int Y { get; set; } - - /// - /// The width in pixels of this form field. - /// - /// The width in pixels of this form field. - [DataMember(Name = "width", EmitDefaultValue = true)] - public int Width { get; set; } - - /// - /// The height in pixels of this form field. - /// - /// The height in pixels of this form field. - [DataMember(Name = "height", EmitDefaultValue = true)] - public int Height { get; set; } - - /// - /// Boolean showing whether or not this field is required. - /// - /// Boolean showing whether or not this field is required. - [DataMember(Name = "required", EmitDefaultValue = true)] - public bool Required { get; set; } - - /// - /// The unique ID for this field. - /// - /// The unique ID for this field. - [DataMember(Name = "api_id", EmitDefaultValue = true)] - public string ApiId { get; set; } - - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - /// - /// The name of the group this field is in. If this field is not a group, this defaults to `null`. - [DataMember(Name = "group", EmitDefaultValue = true)] - public string Group { get; set; } - - /// - /// Gets or Sets AvgTextLength - /// - [DataMember(Name = "avg_text_length", EmitDefaultValue = true)] - public TemplateResponseFieldAvgTextLength AvgTextLength { get; set; } - - /// - /// Whether this form field is multiline text. - /// - /// Whether this form field is multiline text. - [DataMember(Name = "isMultiline", EmitDefaultValue = true)] - public bool? IsMultiline { get; set; } - - /// - /// Original font size used in this form field's text. - /// - /// Original font size used in this form field's text. - [DataMember(Name = "originalFontSize", EmitDefaultValue = true)] - public int? OriginalFontSize { get; set; } - - /// - /// Font family used in this form field's text. - /// - /// Font family used in this form field's text. - [DataMember(Name = "fontFamily", EmitDefaultValue = true)] - public string FontFamily { get; set; } - - /// - /// Returns the string presentation of the object - /// - /// String presentation of the object - public override string ToString() - { - StringBuilder sb = new StringBuilder(); - sb.Append("class TemplateResponseNamedFormField {\n"); - sb.Append(" Name: ").Append(Name).Append("\n"); - sb.Append(" Type: ").Append(Type).Append("\n"); - sb.Append(" Signer: ").Append(Signer).Append("\n"); - sb.Append(" X: ").Append(X).Append("\n"); - sb.Append(" Y: ").Append(Y).Append("\n"); - sb.Append(" Width: ").Append(Width).Append("\n"); - sb.Append(" Height: ").Append(Height).Append("\n"); - sb.Append(" Required: ").Append(Required).Append("\n"); - sb.Append(" ApiId: ").Append(ApiId).Append("\n"); - sb.Append(" Group: ").Append(Group).Append("\n"); - sb.Append(" AvgTextLength: ").Append(AvgTextLength).Append("\n"); - sb.Append(" IsMultiline: ").Append(IsMultiline).Append("\n"); - sb.Append(" OriginalFontSize: ").Append(OriginalFontSize).Append("\n"); - sb.Append(" FontFamily: ").Append(FontFamily).Append("\n"); - sb.Append("}\n"); - return sb.ToString(); - } - - /// - /// Returns the JSON string presentation of the object - /// - /// JSON string presentation of the object - public virtual string ToJson() - { - return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); - } - - /// - /// Returns true if objects are equal - /// - /// Object to be compared - /// Boolean - public override bool Equals(object input) - { - return this.Equals(input as TemplateResponseNamedFormField); - } - - /// - /// Returns true if TemplateResponseNamedFormField instances are equal - /// - /// Instance of TemplateResponseNamedFormField to be compared - /// Boolean - public bool Equals(TemplateResponseNamedFormField input) - { - if (input == null) - { - return false; - } - return - ( - this.Name == input.Name || - (this.Name != null && - this.Name.Equals(input.Name)) - ) && - ( - this.Type == input.Type || - (this.Type != null && - this.Type.Equals(input.Type)) - ) && - ( - this.Signer == input.Signer || - (this.Signer != null && - this.Signer.Equals(input.Signer)) - ) && - ( - this.X == input.X || - this.X.Equals(input.X) - ) && - ( - this.Y == input.Y || - this.Y.Equals(input.Y) - ) && - ( - this.Width == input.Width || - this.Width.Equals(input.Width) - ) && - ( - this.Height == input.Height || - this.Height.Equals(input.Height) - ) && - ( - this.Required == input.Required || - this.Required.Equals(input.Required) - ) && - ( - this.ApiId == input.ApiId || - (this.ApiId != null && - this.ApiId.Equals(input.ApiId)) - ) && - ( - this.Group == input.Group || - (this.Group != null && - this.Group.Equals(input.Group)) - ) && - ( - this.AvgTextLength == input.AvgTextLength || - (this.AvgTextLength != null && - this.AvgTextLength.Equals(input.AvgTextLength)) - ) && - ( - this.IsMultiline == input.IsMultiline || - (this.IsMultiline != null && - this.IsMultiline.Equals(input.IsMultiline)) - ) && - ( - this.OriginalFontSize == input.OriginalFontSize || - (this.OriginalFontSize != null && - this.OriginalFontSize.Equals(input.OriginalFontSize)) - ) && - ( - this.FontFamily == input.FontFamily || - (this.FontFamily != null && - this.FontFamily.Equals(input.FontFamily)) - ); - } - - /// - /// Gets the hash code - /// - /// Hash code - public override int GetHashCode() - { - unchecked // Overflow is fine, just wrap - { - int hashCode = 41; - if (this.Name != null) - { - hashCode = (hashCode * 59) + this.Name.GetHashCode(); - } - if (this.Type != null) - { - hashCode = (hashCode * 59) + this.Type.GetHashCode(); - } - if (this.Signer != null) - { - hashCode = (hashCode * 59) + this.Signer.GetHashCode(); - } - hashCode = (hashCode * 59) + this.X.GetHashCode(); - hashCode = (hashCode * 59) + this.Y.GetHashCode(); - hashCode = (hashCode * 59) + this.Width.GetHashCode(); - hashCode = (hashCode * 59) + this.Height.GetHashCode(); - hashCode = (hashCode * 59) + this.Required.GetHashCode(); - if (this.ApiId != null) - { - hashCode = (hashCode * 59) + this.ApiId.GetHashCode(); - } - if (this.Group != null) - { - hashCode = (hashCode * 59) + this.Group.GetHashCode(); - } - if (this.AvgTextLength != null) - { - hashCode = (hashCode * 59) + this.AvgTextLength.GetHashCode(); - } - if (this.IsMultiline != null) - { - hashCode = (hashCode * 59) + this.IsMultiline.GetHashCode(); - } - if (this.OriginalFontSize != null) - { - hashCode = (hashCode * 59) + this.OriginalFontSize.GetHashCode(); - } - if (this.FontFamily != null) - { - hashCode = (hashCode * 59) + this.FontFamily.GetHashCode(); - } - return hashCode; - } - } - - public List GetOpenApiTypes() - { - var types = new List(); - types.Add(new OpenApiType() - { - Name = "name", - Property = "Name", - Type = "string", - Value = Name, - }); - types.Add(new OpenApiType() - { - Name = "type", - Property = "Type", - Type = "string", - Value = Type, - }); - types.Add(new OpenApiType() - { - Name = "signer", - Property = "Signer", - Type = "string", - Value = Signer, - }); - types.Add(new OpenApiType() - { - Name = "x", - Property = "X", - Type = "int", - Value = X, - }); - types.Add(new OpenApiType() - { - Name = "y", - Property = "Y", - Type = "int", - Value = Y, - }); - types.Add(new OpenApiType() - { - Name = "width", - Property = "Width", - Type = "int", - Value = Width, - }); - types.Add(new OpenApiType() - { - Name = "height", - Property = "Height", - Type = "int", - Value = Height, - }); - types.Add(new OpenApiType() - { - Name = "required", - Property = "Required", - Type = "bool", - Value = Required, - }); - types.Add(new OpenApiType() - { - Name = "api_id", - Property = "ApiId", - Type = "string", - Value = ApiId, - }); - types.Add(new OpenApiType() - { - Name = "group", - Property = "Group", - Type = "string", - Value = Group, - }); - types.Add(new OpenApiType() - { - Name = "avg_text_length", - Property = "AvgTextLength", - Type = "TemplateResponseFieldAvgTextLength", - Value = AvgTextLength, - }); - types.Add(new OpenApiType() - { - Name = "isMultiline", - Property = "IsMultiline", - Type = "bool?", - Value = IsMultiline, - }); - types.Add(new OpenApiType() - { - Name = "originalFontSize", - Property = "OriginalFontSize", - Type = "int?", - Value = OriginalFontSize, - }); - types.Add(new OpenApiType() - { - Name = "fontFamily", - Property = "FontFamily", - Type = "string", - Value = FontFamily, - }); - - return types; - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - public IEnumerable Validate(ValidationContext validationContext) - { - yield break; - } - } - -} diff --git a/sdks/java-v1/run-build b/sdks/java-v1/run-build index 63fcb5cbe..ce4f11eff 100755 --- a/sdks/java-v1/run-build +++ b/sdks/java-v1/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/src/main/java/com/dropbox/sign/api/"*.java +rm -f "${DIR}/src/main/java/com/dropbox/sign/model/"*.java + docker run --rm \ -v "${DIR}/:/local" \ openapitools/openapi-generator-cli:v7.8.0 generate \ diff --git a/sdks/java-v2/run-build b/sdks/java-v2/run-build index ad13373ef..778da00da 100755 --- a/sdks/java-v2/run-build +++ b/sdks/java-v2/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/src/main/java/com/dropbox/sign/api/"*.java +rm -f "${DIR}/src/main/java/com/dropbox/sign/model/"*.java + docker run --rm \ -v "${DIR}/:/local" \ openapitools/openapi-generator-cli:v7.8.0 generate \ diff --git a/sdks/node/run-build b/sdks/node/run-build index 500687ba5..09afd7e37 100755 --- a/sdks/node/run-build +++ b/sdks/node/run-build @@ -12,6 +12,12 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/api/"*.ts +rm -f "${DIR}/model/"*.ts +rm -f "${DIR}/types/api/"*.ts +rm -f "${DIR}/types/model/"*.ts + # Generate code docker run --rm \ -v "${DIR}/:/local" \ diff --git a/sdks/php/run-build b/sdks/php/run-build index de3579e42..8723998b1 100755 --- a/sdks/php/run-build +++ b/sdks/php/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/src/Api/"*.php +rm -f "${DIR}/src/Model/"*.php + docker run --rm \ -v "${DIR}/:/local" \ -v "${DIR}/openapi-sdk.yaml:/local/openapi-sdk.yaml" \ diff --git a/sdks/python/dropbox_sign/models/fax_response_fax.py b/sdks/python/dropbox_sign/models/fax_response_fax.py deleted file mode 100644 index e66df9880..000000000 --- a/sdks/python/dropbox_sign/models/fax_response_fax.py +++ /dev/null @@ -1,187 +0,0 @@ -# coding: utf-8 - -""" - Dropbox Sign API - - Dropbox Sign v3 API - - The version of the OpenAPI document: 3.0.0 - Contact: apisupport@hellosign.com - Generated by OpenAPI Generator (https://openapi-generator.tech) - - Do not edit the class manually. -""" # noqa: E501 - - -from __future__ import annotations -import pprint -import re # noqa: F401 -import json - -from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr -from typing import Any, ClassVar, Dict, List, Optional -from dropbox_sign.models.fax_response_fax_transmission import FaxResponseFaxTransmission -from typing import Optional, Set, Tuple -from typing_extensions import Self -import io -from pydantic import StrictBool -from typing import Union - - -class FaxResponseFax(BaseModel): - """ - FaxResponseFax - """ # noqa: E501 - - fax_id: Optional[StrictStr] = Field(default=None, description="Fax ID") - title: Optional[StrictStr] = Field(default=None, description="Fax Title") - original_title: Optional[StrictStr] = Field( - default=None, description="Fax Original Title" - ) - subject: Optional[StrictStr] = Field(default=None, description="Fax Subject") - message: Optional[StrictStr] = Field(default=None, description="Fax Message") - metadata: Optional[Dict[str, Any]] = Field(default=None, description="Fax Metadata") - created_at: Optional[StrictInt] = Field( - default=None, description="Fax Created At Timestamp" - ) - var_from: Optional[StrictStr] = Field( - default=None, description="Fax Sender Email", alias="from" - ) - transmissions: Optional[List[FaxResponseFaxTransmission]] = Field( - default=None, description="Fax Transmissions List" - ) - files_url: Optional[StrictStr] = Field(default=None, description="Fax Files URL") - __properties: ClassVar[List[str]] = [ - "fax_id", - "title", - "original_title", - "subject", - "message", - "metadata", - "created_at", - "from", - "transmissions", - "files_url", - ] - - model_config = ConfigDict( - populate_by_name=True, - validate_assignment=True, - protected_namespaces=(), - arbitrary_types_allowed=True, - ) - - def to_str(self) -> str: - """Returns the string representation of the model using alias""" - return pprint.pformat(self.model_dump(by_alias=True)) - - def to_json(self) -> str: - """Returns the JSON representation of the model using alias""" - # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead - return json.dumps(self.to_dict()) - - def to_json_form_params( - self, excluded_fields: Set[str] = None - ) -> List[Tuple[str, str]]: - data: List[Tuple[str, str]] = [] - - for key, value in self.to_dict(excluded_fields).items(): - if isinstance(value, (int, str, bool)): - data.append((key, value)) - else: - data.append((key, json.dumps(value, ensure_ascii=False))) - - return data - - @classmethod - def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of FaxResponseFax from a JSON string""" - return cls.from_dict(json.loads(json_str)) - - def to_dict(self, excluded_fields: Set[str] = None) -> Dict[str, Any]: - """Return the dictionary representation of the model using alias. - - This has the following differences from calling pydantic's - `self.model_dump(by_alias=True)`: - - * `None` is only added to the output dict for nullable fields that - were set at model initialization. Other fields with value `None` - are ignored. - """ - - _dict = self.model_dump( - by_alias=True, - exclude=excluded_fields, - exclude_none=True, - ) - # override the default output from pydantic by calling `to_dict()` of each item in transmissions (list) - _items = [] - if self.transmissions: - for _item_transmissions in self.transmissions: - if _item_transmissions: - _items.append(_item_transmissions.to_dict()) - _dict["transmissions"] = _items - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of FaxResponseFax from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate( - { - "fax_id": obj.get("fax_id"), - "title": obj.get("title"), - "original_title": obj.get("original_title"), - "subject": obj.get("subject"), - "message": obj.get("message"), - "metadata": obj.get("metadata"), - "created_at": obj.get("created_at"), - "from": obj.get("from"), - "transmissions": ( - [ - FaxResponseFaxTransmission.from_dict(_item) - for _item in obj["transmissions"] - ] - if obj.get("transmissions") is not None - else None - ), - "files_url": obj.get("files_url"), - } - ) - return _obj - - @classmethod - def init(cls, data: Any) -> Self: - """ - Attempt to instantiate and hydrate a new instance of this class - """ - if isinstance(data, str): - data = json.loads(data) - - return cls.from_dict(data) - - @classmethod - def openapi_types(cls) -> Dict[str, str]: - return { - "fax_id": "(str,)", - "title": "(str,)", - "original_title": "(str,)", - "subject": "(str,)", - "message": "(str,)", - "metadata": "(object,)", - "created_at": "(int,)", - "var_from": "(str,)", - "transmissions": "(List[FaxResponseFaxTransmission],)", - "files_url": "(str,)", - } - - @classmethod - def openapi_type_is_array(cls, property_name: str) -> bool: - return property_name in [ - "transmissions", - ] diff --git a/sdks/python/dropbox_sign/models/fax_response_fax_transmission.py b/sdks/python/dropbox_sign/models/fax_response_fax_transmission.py deleted file mode 100644 index 0c47a93f0..000000000 --- a/sdks/python/dropbox_sign/models/fax_response_fax_transmission.py +++ /dev/null @@ -1,146 +0,0 @@ -# coding: utf-8 - -""" - Dropbox Sign API - - Dropbox Sign v3 API - - The version of the OpenAPI document: 3.0.0 - Contact: apisupport@hellosign.com - Generated by OpenAPI Generator (https://openapi-generator.tech) - - Do not edit the class manually. -""" # noqa: E501 - - -from __future__ import annotations -import pprint -import re # noqa: F401 -import json - -from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr -from typing import Any, ClassVar, Dict, List, Optional -from typing import Optional, Set, Tuple -from typing_extensions import Self -import io -from pydantic import StrictBool -from typing import Union - - -class FaxResponseFaxTransmission(BaseModel): - """ - FaxResponseFaxTransmission - """ # noqa: E501 - - recipient: Optional[StrictStr] = Field( - default=None, description="Fax Transmission Recipient" - ) - sender: Optional[StrictStr] = Field( - default=None, description="Fax Transmission Sender" - ) - status_code: Optional[StrictStr] = Field( - default=None, description="Fax Transmission Status Code" - ) - sent_at: Optional[StrictInt] = Field( - default=None, description="Fax Transmission Sent Timestamp" - ) - __properties: ClassVar[List[str]] = [ - "recipient", - "sender", - "status_code", - "sent_at", - ] - - model_config = ConfigDict( - populate_by_name=True, - validate_assignment=True, - protected_namespaces=(), - arbitrary_types_allowed=True, - ) - - def to_str(self) -> str: - """Returns the string representation of the model using alias""" - return pprint.pformat(self.model_dump(by_alias=True)) - - def to_json(self) -> str: - """Returns the JSON representation of the model using alias""" - # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead - return json.dumps(self.to_dict()) - - def to_json_form_params( - self, excluded_fields: Set[str] = None - ) -> List[Tuple[str, str]]: - data: List[Tuple[str, str]] = [] - - for key, value in self.to_dict(excluded_fields).items(): - if isinstance(value, (int, str, bool)): - data.append((key, value)) - else: - data.append((key, json.dumps(value, ensure_ascii=False))) - - return data - - @classmethod - def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of FaxResponseFaxTransmission from a JSON string""" - return cls.from_dict(json.loads(json_str)) - - def to_dict(self, excluded_fields: Set[str] = None) -> Dict[str, Any]: - """Return the dictionary representation of the model using alias. - - This has the following differences from calling pydantic's - `self.model_dump(by_alias=True)`: - - * `None` is only added to the output dict for nullable fields that - were set at model initialization. Other fields with value `None` - are ignored. - """ - - _dict = self.model_dump( - by_alias=True, - exclude=excluded_fields, - exclude_none=True, - ) - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of FaxResponseFaxTransmission from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate( - { - "recipient": obj.get("recipient"), - "sender": obj.get("sender"), - "status_code": obj.get("status_code"), - "sent_at": obj.get("sent_at"), - } - ) - return _obj - - @classmethod - def init(cls, data: Any) -> Self: - """ - Attempt to instantiate and hydrate a new instance of this class - """ - if isinstance(data, str): - data = json.loads(data) - - return cls.from_dict(data) - - @classmethod - def openapi_types(cls) -> Dict[str, str]: - return { - "recipient": "(str,)", - "sender": "(str,)", - "status_code": "(str,)", - "sent_at": "(int,)", - } - - @classmethod - def openapi_type_is_array(cls, property_name: str) -> bool: - return property_name in [] diff --git a/sdks/python/dropbox_sign/models/sub_file.py b/sdks/python/dropbox_sign/models/sub_file.py deleted file mode 100644 index a3c21e4f7..000000000 --- a/sdks/python/dropbox_sign/models/sub_file.py +++ /dev/null @@ -1,125 +0,0 @@ -# coding: utf-8 - -""" - Dropbox Sign API - - Dropbox Sign v3 API - - The version of the OpenAPI document: 3.0.0 - Contact: apisupport@hellosign.com - Generated by OpenAPI Generator (https://openapi-generator.tech) - - Do not edit the class manually. -""" # noqa: E501 - - -from __future__ import annotations -import pprint -import re # noqa: F401 -import json - -from pydantic import BaseModel, ConfigDict, Field, StrictStr -from typing import Any, ClassVar, Dict, List, Optional -from typing import Optional, Set, Tuple -from typing_extensions import Self -import io -from pydantic import StrictBool -from typing import Union - - -class SubFile(BaseModel): - """ - Actual uploaded physical file - """ # noqa: E501 - - name: Optional[StrictStr] = Field( - default="", - description="Actual physical uploaded file name that is derived during upload. Not settable parameter.", - ) - __properties: ClassVar[List[str]] = ["name"] - - model_config = ConfigDict( - populate_by_name=True, - validate_assignment=True, - protected_namespaces=(), - arbitrary_types_allowed=True, - ) - - def to_str(self) -> str: - """Returns the string representation of the model using alias""" - return pprint.pformat(self.model_dump(by_alias=True)) - - def to_json(self) -> str: - """Returns the JSON representation of the model using alias""" - # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead - return json.dumps(self.to_dict()) - - def to_json_form_params( - self, excluded_fields: Set[str] = None - ) -> List[Tuple[str, str]]: - data: List[Tuple[str, str]] = [] - - for key, value in self.to_dict(excluded_fields).items(): - if isinstance(value, (int, str, bool)): - data.append((key, value)) - else: - data.append((key, json.dumps(value, ensure_ascii=False))) - - return data - - @classmethod - def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of SubFile from a JSON string""" - return cls.from_dict(json.loads(json_str)) - - def to_dict(self, excluded_fields: Set[str] = None) -> Dict[str, Any]: - """Return the dictionary representation of the model using alias. - - This has the following differences from calling pydantic's - `self.model_dump(by_alias=True)`: - - * `None` is only added to the output dict for nullable fields that - were set at model initialization. Other fields with value `None` - are ignored. - """ - - _dict = self.model_dump( - by_alias=True, - exclude=excluded_fields, - exclude_none=True, - ) - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of SubFile from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate( - {"name": obj.get("name") if obj.get("name") is not None else ""} - ) - return _obj - - @classmethod - def init(cls, data: Any) -> Self: - """ - Attempt to instantiate and hydrate a new instance of this class - """ - if isinstance(data, str): - data = json.loads(data) - - return cls.from_dict(data) - - @classmethod - def openapi_types(cls) -> Dict[str, str]: - return { - "name": "(str,)", - } - - @classmethod - def openapi_type_is_array(cls, property_name: str) -> bool: - return property_name in [] diff --git a/sdks/python/run-build b/sdks/python/run-build index 94829a43a..bfa300872 100755 --- a/sdks/python/run-build +++ b/sdks/python/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/dropbox_sign/api/"*.py +rm -f "${DIR}/dropbox_sign/models/"*.py + docker run --rm \ -v "${DIR}/:/local" \ openapitools/openapi-generator-cli:v7.8.0 generate \ diff --git a/sdks/ruby/run-build b/sdks/ruby/run-build index 5df7ba9d4..7127d6455 100755 --- a/sdks/ruby/run-build +++ b/sdks/ruby/run-build @@ -12,6 +12,10 @@ if [[ -n "$GITHUB_ACTIONS" ]]; then echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USERNAME}" --password-stdin fi +# cleanup +rm -f "${DIR}/lib/dropbox-sign/api/"*.rb +rm -f "${DIR}/lib/dropbox-sign/models/"*.rb + docker run --rm \ -v "${DIR}/:/local" \ openapitools/openapi-generator-cli:v7.8.0 generate \