lib/docusign_esign/models/envelope.rb in docusign_esign-2.13.0.rc1 vs lib/docusign_esign/models/envelope.rb in docusign_esign-3.0.0.rc1

- old
+ new

@@ -1,29 +1,39 @@ =begin #DocuSign REST API #The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign. -OpenAPI spec version: v2 +OpenAPI spec version: v2.1 Contact: devcenter@docusign.com Generated by: https://github.com/swagger-api/swagger-codegen.git =end require 'date' module DocuSign_eSign + class Envelope + # + attr_accessor :access_control_list_base64 + + # + attr_accessor :allow_comments + # When set to **true**, Document Markup is enabled for envelope. Account must have Document Markup enabled to use this attr_accessor :allow_markup # When set to **true**, the recipient can redirect an envelope to a more appropriate recipient. attr_accessor :allow_reassign # attr_accessor :allow_view_history + # + attr_accessor :any_signer + # When set to **true**, the envelope is queued for processing and the value of the `status` property is set to 'Processing'. Additionally, get status calls return 'Processing' until completed. attr_accessor :asynchronous # attr_accessor :attachments_uri @@ -47,13 +57,10 @@ attr_accessor :certificate_uri # Specifies the date and time this item was completed. attr_accessor :completed_date_time - # - attr_accessor :copy_recipient_data - # Indicates the date and time the item was created. attr_accessor :created_date_time attr_accessor :custom_fields @@ -90,52 +97,106 @@ attr_accessor :enable_wet_sign # When set to **true**, documents with tabs can only be viewed by signers that have a tab on that document. Recipients that have an administrative role (Agent, Editor, or Intermediaries) or informational role (Certified Deliveries or Carbon Copies) can always see all the documents in an envelope, unless they are specifically excluded using this setting when an envelope is sent. Documents that do not have tabs are always visible to all recipients, unless they are specifically excluded using this setting when an envelope is sent. Your account must have Document Visibility enabled to use this. attr_accessor :enforce_signer_visibility + # + attr_accessor :envelope_attachments + + # + attr_accessor :envelope_documents + # The envelope ID of the envelope status that failed to post. attr_accessor :envelope_id # When set to **true**, Envelope ID Stamping is enabled. attr_accessor :envelope_id_stamping + # + attr_accessor :envelope_location + + attr_accessor :envelope_metadata + # Contains a URI for an endpoint that you can use to retrieve the envelope or envelopes. attr_accessor :envelope_uri # + attr_accessor :expire_after + + # + attr_accessor :expire_date_time + + # + attr_accessor :expire_enabled + + # + attr_accessor :external_envelope_id + + # + attr_accessor :folders + + # + attr_accessor :has_comments + + # + attr_accessor :has_form_data_changed + + # + attr_accessor :has_wav_file + + # + attr_accessor :holder + + # attr_accessor :initial_sent_date_time # When set to **true**, indicates that this module is enabled on the account. attr_accessor :is21_cfr_part11 # + attr_accessor :is_dynamic_envelope + + # attr_accessor :is_signature_provider_envelope # The date and time the item was last modified. attr_accessor :last_modified_date_time + # + attr_accessor :location + attr_accessor :lock_information # When set to **true**, prevents senders from changing the contents of `emailBlurb` and `emailSubject` properties for the envelope. Additionally, this prevents users from making changes to the contents of `emailBlurb` and `emailSubject` properties when correcting envelopes. However, if the `messageLock` node is set to true**** and the `emailSubject` property is empty, senders and correctors are able to add a subject to the envelope. attr_accessor :message_lock attr_accessor :notification # Contains a URI for an endpoint that you can use to retrieve the notifications. attr_accessor :notification_uri + attr_accessor :power_form + # + attr_accessor :purge_completed_date + + # + attr_accessor :purge_request_date + + # attr_accessor :purge_state attr_accessor :recipients # When set to **true**, prevents senders from changing, correcting, or deleting the recipient information for the envelope. attr_accessor :recipients_lock # Contains a URI for an endpoint that you can use to retrieve the recipients. attr_accessor :recipients_uri + attr_accessor :sender + # The date and time the envelope was sent. attr_accessor :sent_date_time # attr_accessor :signer_can_sign_on_mobile @@ -147,10 +208,13 @@ attr_accessor :status # The data and time the status changed. attr_accessor :status_changed_date_time + # + attr_accessor :status_date_time + # Contains a URI for an endpoint which you can use to retrieve the templates. attr_accessor :templates_uri # Used to identify an envelope. The id is a sender-generated value and is valid in the DocuSign system for 7 days. It is recommended that a transaction ID is used for offline signing to ensure that an envelope is not sent multiple times. The `transactionId` property can be used determine an envelope's status (i.e. was it created or not) in cases where the internet connection was lost before the envelope status was returned. attr_accessor :transaction_id @@ -162,26 +226,29 @@ attr_accessor :voided_date_time # The reason the envelope or template was voided. attr_accessor :voided_reason + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { + :'access_control_list_base64' => :'accessControlListBase64', + :'allow_comments' => :'allowComments', :'allow_markup' => :'allowMarkup', :'allow_reassign' => :'allowReassign', :'allow_view_history' => :'allowViewHistory', + :'any_signer' => :'anySigner', :'asynchronous' => :'asynchronous', :'attachments_uri' => :'attachmentsUri', :'authoritative_copy' => :'authoritativeCopy', :'authoritative_copy_default' => :'authoritativeCopyDefault', :'auto_navigation' => :'autoNavigation', :'brand_id' => :'brandId', :'brand_lock' => :'brandLock', :'certificate_uri' => :'certificateUri', :'completed_date_time' => :'completedDateTime', - :'copy_recipient_data' => :'copyRecipientData', :'created_date_time' => :'createdDateTime', :'custom_fields' => :'customFields', :'custom_fields_uri' => :'customFieldsUri', :'declined_date_time' => :'declinedDateTime', :'deleted_date_time' => :'deletedDateTime', @@ -192,30 +259,50 @@ :'email_blurb' => :'emailBlurb', :'email_settings' => :'emailSettings', :'email_subject' => :'emailSubject', :'enable_wet_sign' => :'enableWetSign', :'enforce_signer_visibility' => :'enforceSignerVisibility', + :'envelope_attachments' => :'envelopeAttachments', + :'envelope_documents' => :'envelopeDocuments', :'envelope_id' => :'envelopeId', :'envelope_id_stamping' => :'envelopeIdStamping', + :'envelope_location' => :'envelopeLocation', + :'envelope_metadata' => :'envelopeMetadata', :'envelope_uri' => :'envelopeUri', + :'expire_after' => :'expireAfter', + :'expire_date_time' => :'expireDateTime', + :'expire_enabled' => :'expireEnabled', + :'external_envelope_id' => :'externalEnvelopeId', + :'folders' => :'folders', + :'has_comments' => :'hasComments', + :'has_form_data_changed' => :'hasFormDataChanged', + :'has_wav_file' => :'hasWavFile', + :'holder' => :'holder', :'initial_sent_date_time' => :'initialSentDateTime', :'is21_cfr_part11' => :'is21CFRPart11', + :'is_dynamic_envelope' => :'isDynamicEnvelope', :'is_signature_provider_envelope' => :'isSignatureProviderEnvelope', :'last_modified_date_time' => :'lastModifiedDateTime', + :'location' => :'location', :'lock_information' => :'lockInformation', :'message_lock' => :'messageLock', :'notification' => :'notification', :'notification_uri' => :'notificationUri', + :'power_form' => :'powerForm', + :'purge_completed_date' => :'purgeCompletedDate', + :'purge_request_date' => :'purgeRequestDate', :'purge_state' => :'purgeState', :'recipients' => :'recipients', :'recipients_lock' => :'recipientsLock', :'recipients_uri' => :'recipientsUri', + :'sender' => :'sender', :'sent_date_time' => :'sentDateTime', :'signer_can_sign_on_mobile' => :'signerCanSignOnMobile', :'signing_location' => :'signingLocation', :'status' => :'status', :'status_changed_date_time' => :'statusChangedDateTime', + :'status_date_time' => :'statusDateTime', :'templates_uri' => :'templatesUri', :'transaction_id' => :'transactionId', :'use_disclosure' => :'useDisclosure', :'voided_date_time' => :'voidedDateTime', :'voided_reason' => :'voidedReason' @@ -223,23 +310,25 @@ end # Attribute type mapping. def self.swagger_types { + :'access_control_list_base64' => :'String', + :'allow_comments' => :'String', :'allow_markup' => :'String', :'allow_reassign' => :'String', :'allow_view_history' => :'String', + :'any_signer' => :'String', :'asynchronous' => :'String', :'attachments_uri' => :'String', :'authoritative_copy' => :'String', :'authoritative_copy_default' => :'String', :'auto_navigation' => :'String', :'brand_id' => :'String', :'brand_lock' => :'String', :'certificate_uri' => :'String', :'completed_date_time' => :'String', - :'copy_recipient_data' => :'String', :'created_date_time' => :'String', :'custom_fields' => :'CustomFields', :'custom_fields_uri' => :'String', :'declined_date_time' => :'String', :'deleted_date_time' => :'String', @@ -250,30 +339,50 @@ :'email_blurb' => :'String', :'email_settings' => :'EmailSettings', :'email_subject' => :'String', :'enable_wet_sign' => :'String', :'enforce_signer_visibility' => :'String', + :'envelope_attachments' => :'Array<Attachment>', + :'envelope_documents' => :'Array<EnvelopeDocument>', :'envelope_id' => :'String', :'envelope_id_stamping' => :'String', + :'envelope_location' => :'String', + :'envelope_metadata' => :'EnvelopeMetadata', :'envelope_uri' => :'String', + :'expire_after' => :'String', + :'expire_date_time' => :'String', + :'expire_enabled' => :'String', + :'external_envelope_id' => :'String', + :'folders' => :'Array<Folder>', + :'has_comments' => :'String', + :'has_form_data_changed' => :'String', + :'has_wav_file' => :'String', + :'holder' => :'String', :'initial_sent_date_time' => :'String', :'is21_cfr_part11' => :'String', + :'is_dynamic_envelope' => :'String', :'is_signature_provider_envelope' => :'String', :'last_modified_date_time' => :'String', + :'location' => :'String', :'lock_information' => :'LockInformation', :'message_lock' => :'String', :'notification' => :'Notification', :'notification_uri' => :'String', + :'power_form' => :'PowerForm', + :'purge_completed_date' => :'String', + :'purge_request_date' => :'String', :'purge_state' => :'String', :'recipients' => :'Recipients', :'recipients_lock' => :'String', :'recipients_uri' => :'String', + :'sender' => :'UserInfo', :'sent_date_time' => :'String', :'signer_can_sign_on_mobile' => :'String', :'signing_location' => :'String', :'status' => :'String', :'status_changed_date_time' => :'String', + :'status_date_time' => :'String', :'templates_uri' => :'String', :'transaction_id' => :'String', :'use_disclosure' => :'String', :'voided_date_time' => :'String', :'voided_reason' => :'String' @@ -284,12 +393,20 @@ # @param [Hash] attributes Model attributes in the form of hash def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key - attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } + attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v} + if attributes.has_key?(:'accessControlListBase64') + self.access_control_list_base64 = attributes[:'accessControlListBase64'] + end + + if attributes.has_key?(:'allowComments') + self.allow_comments = attributes[:'allowComments'] + end + if attributes.has_key?(:'allowMarkup') self.allow_markup = attributes[:'allowMarkup'] end if attributes.has_key?(:'allowReassign') @@ -298,10 +415,14 @@ if attributes.has_key?(:'allowViewHistory') self.allow_view_history = attributes[:'allowViewHistory'] end + if attributes.has_key?(:'anySigner') + self.any_signer = attributes[:'anySigner'] + end + if attributes.has_key?(:'asynchronous') self.asynchronous = attributes[:'asynchronous'] end if attributes.has_key?(:'attachmentsUri') @@ -334,14 +455,10 @@ if attributes.has_key?(:'completedDateTime') self.completed_date_time = attributes[:'completedDateTime'] end - if attributes.has_key?(:'copyRecipientData') - self.copy_recipient_data = attributes[:'copyRecipientData'] - end - if attributes.has_key?(:'createdDateTime') self.created_date_time = attributes[:'createdDateTime'] end if attributes.has_key?(:'customFields') @@ -394,38 +511,104 @@ if attributes.has_key?(:'enforceSignerVisibility') self.enforce_signer_visibility = attributes[:'enforceSignerVisibility'] end + if attributes.has_key?(:'envelopeAttachments') + if (value = attributes[:'envelopeAttachments']).is_a?(Array) + self.envelope_attachments = value + end + end + + if attributes.has_key?(:'envelopeDocuments') + if (value = attributes[:'envelopeDocuments']).is_a?(Array) + self.envelope_documents = value + end + end + if attributes.has_key?(:'envelopeId') self.envelope_id = attributes[:'envelopeId'] end if attributes.has_key?(:'envelopeIdStamping') self.envelope_id_stamping = attributes[:'envelopeIdStamping'] end + if attributes.has_key?(:'envelopeLocation') + self.envelope_location = attributes[:'envelopeLocation'] + end + + if attributes.has_key?(:'envelopeMetadata') + self.envelope_metadata = attributes[:'envelopeMetadata'] + end + if attributes.has_key?(:'envelopeUri') self.envelope_uri = attributes[:'envelopeUri'] end + if attributes.has_key?(:'expireAfter') + self.expire_after = attributes[:'expireAfter'] + end + + if attributes.has_key?(:'expireDateTime') + self.expire_date_time = attributes[:'expireDateTime'] + end + + if attributes.has_key?(:'expireEnabled') + self.expire_enabled = attributes[:'expireEnabled'] + end + + if attributes.has_key?(:'externalEnvelopeId') + self.external_envelope_id = attributes[:'externalEnvelopeId'] + end + + if attributes.has_key?(:'folders') + if (value = attributes[:'folders']).is_a?(Array) + self.folders = value + end + end + + if attributes.has_key?(:'hasComments') + self.has_comments = attributes[:'hasComments'] + end + + if attributes.has_key?(:'hasFormDataChanged') + self.has_form_data_changed = attributes[:'hasFormDataChanged'] + end + + if attributes.has_key?(:'hasWavFile') + self.has_wav_file = attributes[:'hasWavFile'] + end + + if attributes.has_key?(:'holder') + self.holder = attributes[:'holder'] + end + if attributes.has_key?(:'initialSentDateTime') self.initial_sent_date_time = attributes[:'initialSentDateTime'] end if attributes.has_key?(:'is21CFRPart11') self.is21_cfr_part11 = attributes[:'is21CFRPart11'] end + if attributes.has_key?(:'isDynamicEnvelope') + self.is_dynamic_envelope = attributes[:'isDynamicEnvelope'] + end + if attributes.has_key?(:'isSignatureProviderEnvelope') self.is_signature_provider_envelope = attributes[:'isSignatureProviderEnvelope'] end if attributes.has_key?(:'lastModifiedDateTime') self.last_modified_date_time = attributes[:'lastModifiedDateTime'] end + if attributes.has_key?(:'location') + self.location = attributes[:'location'] + end + if attributes.has_key?(:'lockInformation') self.lock_information = attributes[:'lockInformation'] end if attributes.has_key?(:'messageLock') @@ -438,10 +621,22 @@ if attributes.has_key?(:'notificationUri') self.notification_uri = attributes[:'notificationUri'] end + if attributes.has_key?(:'powerForm') + self.power_form = attributes[:'powerForm'] + end + + if attributes.has_key?(:'purgeCompletedDate') + self.purge_completed_date = attributes[:'purgeCompletedDate'] + end + + if attributes.has_key?(:'purgeRequestDate') + self.purge_request_date = attributes[:'purgeRequestDate'] + end + if attributes.has_key?(:'purgeState') self.purge_state = attributes[:'purgeState'] end if attributes.has_key?(:'recipients') @@ -454,10 +649,14 @@ if attributes.has_key?(:'recipientsUri') self.recipients_uri = attributes[:'recipientsUri'] end + if attributes.has_key?(:'sender') + self.sender = attributes[:'sender'] + end + if attributes.has_key?(:'sentDateTime') self.sent_date_time = attributes[:'sentDateTime'] end if attributes.has_key?(:'signerCanSignOnMobile') @@ -474,10 +673,14 @@ if attributes.has_key?(:'statusChangedDateTime') self.status_changed_date_time = attributes[:'statusChangedDateTime'] end + if attributes.has_key?(:'statusDateTime') + self.status_date_time = attributes[:'statusDateTime'] + end + if attributes.has_key?(:'templatesUri') self.templates_uri = attributes[:'templatesUri'] end if attributes.has_key?(:'transactionId') @@ -493,43 +696,46 @@ end if attributes.has_key?(:'voidedReason') self.voided_reason = attributes[:'voidedReason'] end + end # Show invalid properties with the reasons. Usually used together with valid? - # @return Array for valid properties with the reasons + # @return Array for valid properies with the reasons def list_invalid_properties invalid_properties = Array.new - invalid_properties + return invalid_properties end # Check to see if the all the properties in the model are valid # @return true if the model is valid def valid? - true + return true end # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) return true if self.equal?(o) self.class == o.class && + access_control_list_base64 == o.access_control_list_base64 && + allow_comments == o.allow_comments && allow_markup == o.allow_markup && allow_reassign == o.allow_reassign && allow_view_history == o.allow_view_history && + any_signer == o.any_signer && asynchronous == o.asynchronous && attachments_uri == o.attachments_uri && authoritative_copy == o.authoritative_copy && authoritative_copy_default == o.authoritative_copy_default && auto_navigation == o.auto_navigation && brand_id == o.brand_id && brand_lock == o.brand_lock && certificate_uri == o.certificate_uri && completed_date_time == o.completed_date_time && - copy_recipient_data == o.copy_recipient_data && created_date_time == o.created_date_time && custom_fields == o.custom_fields && custom_fields_uri == o.custom_fields_uri && declined_date_time == o.declined_date_time && deleted_date_time == o.deleted_date_time && @@ -540,30 +746,50 @@ email_blurb == o.email_blurb && email_settings == o.email_settings && email_subject == o.email_subject && enable_wet_sign == o.enable_wet_sign && enforce_signer_visibility == o.enforce_signer_visibility && + envelope_attachments == o.envelope_attachments && + envelope_documents == o.envelope_documents && envelope_id == o.envelope_id && envelope_id_stamping == o.envelope_id_stamping && + envelope_location == o.envelope_location && + envelope_metadata == o.envelope_metadata && envelope_uri == o.envelope_uri && + expire_after == o.expire_after && + expire_date_time == o.expire_date_time && + expire_enabled == o.expire_enabled && + external_envelope_id == o.external_envelope_id && + folders == o.folders && + has_comments == o.has_comments && + has_form_data_changed == o.has_form_data_changed && + has_wav_file == o.has_wav_file && + holder == o.holder && initial_sent_date_time == o.initial_sent_date_time && is21_cfr_part11 == o.is21_cfr_part11 && + is_dynamic_envelope == o.is_dynamic_envelope && is_signature_provider_envelope == o.is_signature_provider_envelope && last_modified_date_time == o.last_modified_date_time && + location == o.location && lock_information == o.lock_information && message_lock == o.message_lock && notification == o.notification && notification_uri == o.notification_uri && + power_form == o.power_form && + purge_completed_date == o.purge_completed_date && + purge_request_date == o.purge_request_date && purge_state == o.purge_state && recipients == o.recipients && recipients_lock == o.recipients_lock && recipients_uri == o.recipients_uri && + sender == o.sender && sent_date_time == o.sent_date_time && signer_can_sign_on_mobile == o.signer_can_sign_on_mobile && signing_location == o.signing_location && status == o.status && status_changed_date_time == o.status_changed_date_time && + status_date_time == o.status_date_time && templates_uri == o.templates_uri && transaction_id == o.transaction_id && use_disclosure == o.use_disclosure && voided_date_time == o.voided_date_time && voided_reason == o.voided_reason @@ -576,24 +802,24 @@ end # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [allow_markup, allow_reassign, allow_view_history, asynchronous, attachments_uri, authoritative_copy, authoritative_copy_default, auto_navigation, brand_id, brand_lock, certificate_uri, completed_date_time, copy_recipient_data, created_date_time, custom_fields, custom_fields_uri, declined_date_time, deleted_date_time, delivered_date_time, disable_responsive_document, documents_combined_uri, documents_uri, email_blurb, email_settings, email_subject, enable_wet_sign, enforce_signer_visibility, envelope_id, envelope_id_stamping, envelope_uri, initial_sent_date_time, is21_cfr_part11, is_signature_provider_envelope, last_modified_date_time, lock_information, message_lock, notification, notification_uri, purge_state, recipients, recipients_lock, recipients_uri, sent_date_time, signer_can_sign_on_mobile, signing_location, status, status_changed_date_time, templates_uri, transaction_id, use_disclosure, voided_date_time, voided_reason].hash + [access_control_list_base64, allow_comments, allow_markup, allow_reassign, allow_view_history, any_signer, asynchronous, attachments_uri, authoritative_copy, authoritative_copy_default, auto_navigation, brand_id, brand_lock, certificate_uri, completed_date_time, created_date_time, custom_fields, custom_fields_uri, declined_date_time, deleted_date_time, delivered_date_time, disable_responsive_document, documents_combined_uri, documents_uri, email_blurb, email_settings, email_subject, enable_wet_sign, enforce_signer_visibility, envelope_attachments, envelope_documents, envelope_id, envelope_id_stamping, envelope_location, envelope_metadata, envelope_uri, expire_after, expire_date_time, expire_enabled, external_envelope_id, folders, has_comments, has_form_data_changed, has_wav_file, holder, initial_sent_date_time, is21_cfr_part11, is_dynamic_envelope, is_signature_provider_envelope, last_modified_date_time, location, lock_information, message_lock, notification, notification_uri, power_form, purge_completed_date, purge_request_date, purge_state, recipients, recipients_lock, recipients_uri, sender, sent_date_time, signer_can_sign_on_mobile, signing_location, status, status_changed_date_time, status_date_time, templates_uri, transaction_id, use_disclosure, voided_date_time, voided_reason].hash end # Builds the object from hash # @param [Hash] attributes Model attributes in the form of hash # @return [Object] Returns the model itself def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /\AArray<(.*)>/i - # check to ensure the input is an array given that the attribute + # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) - self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) + self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) end # or else data not found in attributes(hash), not an issue as the data can be optional end @@ -671,11 +897,11 @@ # For object, use to_hash. Otherwise, just return the value # @param [Object] value Any valid value # @return [Hash] Returns the value in the form of hash def _to_hash(value) if value.is_a?(Array) - value.compact.map { |v| _to_hash(v) } + value.compact.map{ |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash @@ -684,6 +910,7 @@ value end end end + end