lib/hello_sign/api/signature_request.rb in hellosign-ruby-sdk-3.2.3 vs lib/hello_sign/api/signature_request.rb in hellosign-ruby-sdk-3.2.4
- old
+ new
@@ -35,33 +35,38 @@
module SignatureRequest
#
# Retrieves a Signature Request with the given ID.
# @option opts [String] signature_request_id The id of the SignatureRequest to retrieve.
+ # @option opts [Integer] ux_version sets the version of the signer page to use
#
# @return [HelloSign::Resource::SignatureRequest] a SignatureRequest object
#
# @example
# signature_request = @client.get_signature_request :signature_request_id => 'fa5c8a0b0f492d768749333ad6fcc214c111e967'
#
def get_signature_request(opts)
- HelloSign::Resource::SignatureRequest.new get("/signature_request/#{opts[:signature_request_id]}")
+ path = "/signature_request/#{opts[:signature_request_id]}"
+ query = create_query_string(opts, [:ux_version])
+ path += query
+ HelloSign::Resource::SignatureRequest.new get(path)
end
#
# Returns a list of SignatureRequests that you can access. This includes SignatureRequests you have sent as well as received, but not ones that you have been CCed on.
# @option opts [Integer] page (1) Which page number of the Template List to return.
+ # @option opts [Integer] ux_version sets the version of the signer page to use
#
# @return [HelloSign::Resource::ResourceArray]
#
# @example
# signature_requests = @client.get_signature_requests :page => 1
#
def get_signature_requests(opts={})
path = '/signature_request/list'
- path += opts[:page] ? "?page=#{opts[:page]}" : ''
- path += opts[:page_size] ? "&page_size=#{opts[:page_size]}" : ''
+ query = create_query_string(opts, [:page, :page_size, :ux_version])
+ path += query
HelloSign::Resource::ResourceArray.new get(path, opts), 'signature_requests', HelloSign::Resource::SignatureRequest
end
#
# Creates and sends a new SignatureRequest with the submitted documents.
@@ -129,10 +134,11 @@
# * :email_address (String) Sender's email address
# * :order (Integer) The order the signer is required to sign in
# * :pin (Integer) The 4- to 12-character access code that will secure this signer's signature page. You must have a business plan to use this feature.
# @option opts [Array<Hash>] ccs The email addresses CC destinations. Required when a CC role exists for the Template.
# @option opts [Array<Hash>] custom_fields The value to fill in for the custom field with the name of CustomFieldName. Required when a CustomField exists in the Template.
+ # @option opts [Integer] ux_version sets the version of the signer page to use
#
# @return [HelloSign::Resource::SignatureRequest] a SignatureRequest
# @example
# signature_request = @client.send_signature_request_with_template(
# :test_mode => 1,
@@ -200,10 +206,11 @@
#
# Sends an email to the signer reminding them to sign the signature request.
# @option opts [String] signature_request_id The id of the SignatureRequest to send a reminder for.
# @option opts [String] email_address The email address of the signer to send a reminder to.
+ # @option opts [Integer] ux_version sets the version of the signer page to use
#
# @return [HelloSign::Resource::SignatureRequest] a SignatureRequest
# @example
# signature_request = @client.remind_signature_request :signature_request_id => '75cdf7dc8b323d43b347e4a3614d1f822bd09491', :email_address => 'john@example.com'
#
@@ -256,10 +263,11 @@
# * :email_address (String) Sender's email address
# * :order (Integer) The order the signer is required to sign in
# * :pin (Integer) The 4- to 12-character access code that will secure this signer's signature page. You must have a business plan to use this feature.
# @option opts [Array<String>] cc_email_addresses The email addresses that should be CCed.
# @option opts [String] form_fields_per_document
+ # @option opts [Integer] ux_version sets the version of the signer page to use
#
# @return [HelloSign::Resource::SignatureRequest] a SignatureRequest
# @example
# request = @client.create_embedded_signature_request(
# :test_mode => 1,
@@ -310,9 +318,11 @@
# * :email_address (String) Sender's email address
# * :order (Integer) The order the signer is required to sign in
# * :pin (Integer) The 4- to 12-character access code that will secure this signer's signature page. You must have a business plan to use this feature.
# @option opts [Hash] ccs The email address of the CC filling the role of RoleName. Required when a CC role exists for the Template.
# @option opts [Hash] custom_fields The value to fill in for custom field with the name of CustomFieldName. Required when a CustomField exists in the Template.
+ # @option opts [Integer] ux_version sets the version of the signer page to use
+ #
# @return [HelloSign::Resource::SignatureRequest] a SignatureRequest
# @example
# request = @client.create_embedded_signature_request_with_template(
# :test_mode => 1,
# :client_id => 'b6b8e7deaf8f0b95c029dca049356d4a2cf9710a',