docusign_click 1.3.0 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/docusign_click/client/api_client.rb +8 -3
- data/lib/docusign_click/models/agree_button_styles.rb +395 -0
- data/lib/docusign_click/models/agreement_statement_styles.rb +269 -0
- data/lib/docusign_click/models/base_agree_button_styles.rb +364 -0
- data/lib/docusign_click/models/container_styles.rb +225 -0
- data/lib/docusign_click/models/disclosure_link_styles.rb +218 -0
- data/lib/docusign_click/models/document_link_styles.rb +283 -0
- data/lib/docusign_click/models/document_link_styles_focus.rb +264 -0
- data/lib/docusign_click/models/header_styles.rb +279 -0
- data/lib/docusign_click/models/user_agreement_response.rb +2 -5
- data/lib/docusign_click/models/user_agreement_response_style.rb +279 -0
- data/lib/docusign_click/version.rb +1 -1
- data/lib/docusign_click.rb +9 -0
- metadata +11 -2
@@ -0,0 +1,279 @@
|
|
1
|
+
=begin
|
2
|
+
#DocuSign Click API
|
3
|
+
|
4
|
+
#Elastic signing (also known as DocuSign Click) lets you capture consent to standard agreement terms with a single click: terms and conditions, terms of service, terms of use, privacy policies, and more. The Click API lets you include this customizable elastic template solution in your DocuSign integrations.
|
5
|
+
|
6
|
+
OpenAPI spec version: v1
|
7
|
+
Contact: devcenter@docusign.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module DocuSign_Click
|
15
|
+
# Control the display of the header.
|
16
|
+
class HeaderStyles
|
17
|
+
# Control the fore-ground color of the element.
|
18
|
+
attr_accessor :color
|
19
|
+
|
20
|
+
# Control the display of the header. Can only be set to 'none' over the default for hiding purposes.
|
21
|
+
attr_accessor :display
|
22
|
+
|
23
|
+
# Control the font family of the text.
|
24
|
+
attr_accessor :font_family
|
25
|
+
|
26
|
+
# Control the font size of the text.
|
27
|
+
attr_accessor :font_size
|
28
|
+
|
29
|
+
# Control the font style of the text.
|
30
|
+
attr_accessor :font_style
|
31
|
+
|
32
|
+
# Control the font weight of the text.
|
33
|
+
attr_accessor :font_weight
|
34
|
+
|
35
|
+
# Control the underline and other styles of the text.
|
36
|
+
attr_accessor :text_decoration
|
37
|
+
|
38
|
+
class EnumAttributeValidator
|
39
|
+
attr_reader :datatype
|
40
|
+
attr_reader :allowable_values
|
41
|
+
|
42
|
+
def initialize(datatype, allowable_values)
|
43
|
+
@allowable_values = allowable_values.map do |value|
|
44
|
+
case datatype.to_s
|
45
|
+
when /Integer/i
|
46
|
+
value.to_i
|
47
|
+
when /Float/i
|
48
|
+
value.to_f
|
49
|
+
else
|
50
|
+
value
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
def valid?(value)
|
56
|
+
!value || allowable_values.include?(value)
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
61
|
+
def self.attribute_map
|
62
|
+
{
|
63
|
+
:'color' => :'color',
|
64
|
+
:'display' => :'display',
|
65
|
+
:'font_family' => :'fontFamily',
|
66
|
+
:'font_size' => :'fontSize',
|
67
|
+
:'font_style' => :'fontStyle',
|
68
|
+
:'font_weight' => :'fontWeight',
|
69
|
+
:'text_decoration' => :'textDecoration'
|
70
|
+
}
|
71
|
+
end
|
72
|
+
|
73
|
+
# Attribute type mapping.
|
74
|
+
def self.swagger_types
|
75
|
+
{
|
76
|
+
:'color' => :'String',
|
77
|
+
:'display' => :'String',
|
78
|
+
:'font_family' => :'String',
|
79
|
+
:'font_size' => :'String',
|
80
|
+
:'font_style' => :'String',
|
81
|
+
:'font_weight' => :'Object',
|
82
|
+
:'text_decoration' => :'String'
|
83
|
+
}
|
84
|
+
end
|
85
|
+
|
86
|
+
# Initializes the object
|
87
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
88
|
+
def initialize(attributes = {})
|
89
|
+
return unless attributes.is_a?(Hash)
|
90
|
+
|
91
|
+
# convert string to symbol for hash key
|
92
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
93
|
+
|
94
|
+
if attributes.has_key?(:'color')
|
95
|
+
self.color = attributes[:'color']
|
96
|
+
end
|
97
|
+
|
98
|
+
if attributes.has_key?(:'display')
|
99
|
+
self.display = attributes[:'display']
|
100
|
+
end
|
101
|
+
|
102
|
+
if attributes.has_key?(:'fontFamily')
|
103
|
+
self.font_family = attributes[:'fontFamily']
|
104
|
+
end
|
105
|
+
|
106
|
+
if attributes.has_key?(:'fontSize')
|
107
|
+
self.font_size = attributes[:'fontSize']
|
108
|
+
end
|
109
|
+
|
110
|
+
if attributes.has_key?(:'fontStyle')
|
111
|
+
self.font_style = attributes[:'fontStyle']
|
112
|
+
end
|
113
|
+
|
114
|
+
if attributes.has_key?(:'fontWeight')
|
115
|
+
self.font_weight = attributes[:'fontWeight']
|
116
|
+
end
|
117
|
+
|
118
|
+
if attributes.has_key?(:'textDecoration')
|
119
|
+
self.text_decoration = attributes[:'textDecoration']
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
124
|
+
# @return Array for valid properties with the reasons
|
125
|
+
def list_invalid_properties
|
126
|
+
invalid_properties = Array.new
|
127
|
+
invalid_properties
|
128
|
+
end
|
129
|
+
|
130
|
+
# Check to see if the all the properties in the model are valid
|
131
|
+
# @return true if the model is valid
|
132
|
+
def valid?
|
133
|
+
display_validator = EnumAttributeValidator.new('String', ['none'])
|
134
|
+
return false unless display_validator.valid?(@display)
|
135
|
+
true
|
136
|
+
end
|
137
|
+
|
138
|
+
# Custom attribute writer method checking allowed values (enum).
|
139
|
+
# @param [Object] display Object to be assigned
|
140
|
+
def display=(display)
|
141
|
+
validator = EnumAttributeValidator.new('String', ['none'])
|
142
|
+
unless validator.valid?(display)
|
143
|
+
fail ArgumentError, 'invalid value for "display", must be one of #{validator.allowable_values}.'
|
144
|
+
end
|
145
|
+
@display = display
|
146
|
+
end
|
147
|
+
|
148
|
+
# Checks equality by comparing each attribute.
|
149
|
+
# @param [Object] Object to be compared
|
150
|
+
def ==(o)
|
151
|
+
return true if self.equal?(o)
|
152
|
+
self.class == o.class &&
|
153
|
+
color == o.color &&
|
154
|
+
display == o.display &&
|
155
|
+
font_family == o.font_family &&
|
156
|
+
font_size == o.font_size &&
|
157
|
+
font_style == o.font_style &&
|
158
|
+
font_weight == o.font_weight &&
|
159
|
+
text_decoration == o.text_decoration
|
160
|
+
end
|
161
|
+
|
162
|
+
# @see the `==` method
|
163
|
+
# @param [Object] Object to be compared
|
164
|
+
def eql?(o)
|
165
|
+
self == o
|
166
|
+
end
|
167
|
+
|
168
|
+
# Calculates hash code according to all attributes.
|
169
|
+
# @return [Fixnum] Hash code
|
170
|
+
def hash
|
171
|
+
[color, display, font_family, font_size, font_style, font_weight, text_decoration].hash
|
172
|
+
end
|
173
|
+
|
174
|
+
# Builds the object from hash
|
175
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
176
|
+
# @return [Object] Returns the model itself
|
177
|
+
def build_from_hash(attributes)
|
178
|
+
return nil unless attributes.is_a?(Hash)
|
179
|
+
self.class.swagger_types.each_pair do |key, type|
|
180
|
+
if type =~ /\AArray<(.*)>/i
|
181
|
+
# check to ensure the input is an array given that the attribute
|
182
|
+
# is documented as an array but the input is not
|
183
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
184
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
185
|
+
end
|
186
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
187
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
188
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
189
|
+
end
|
190
|
+
|
191
|
+
self
|
192
|
+
end
|
193
|
+
|
194
|
+
# Deserializes the data based on type
|
195
|
+
# @param string type Data type
|
196
|
+
# @param string value Value to be deserialized
|
197
|
+
# @return [Object] Deserialized data
|
198
|
+
def _deserialize(type, value)
|
199
|
+
case type.to_sym
|
200
|
+
when :DateTime
|
201
|
+
DateTime.parse(value)
|
202
|
+
when :Date
|
203
|
+
Date.parse(value)
|
204
|
+
when :String
|
205
|
+
value.to_s
|
206
|
+
when :Integer
|
207
|
+
value.to_i
|
208
|
+
when :Float
|
209
|
+
value.to_f
|
210
|
+
when :BOOLEAN
|
211
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
212
|
+
true
|
213
|
+
else
|
214
|
+
false
|
215
|
+
end
|
216
|
+
when :Object
|
217
|
+
# generic object (usually a Hash), return directly
|
218
|
+
value
|
219
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
220
|
+
inner_type = Regexp.last_match[:inner_type]
|
221
|
+
value.map { |v| _deserialize(inner_type, v) }
|
222
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
223
|
+
k_type = Regexp.last_match[:k_type]
|
224
|
+
v_type = Regexp.last_match[:v_type]
|
225
|
+
{}.tap do |hash|
|
226
|
+
value.each do |k, v|
|
227
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
228
|
+
end
|
229
|
+
end
|
230
|
+
else # model
|
231
|
+
temp_model = DocuSign_Click.const_get(type).new
|
232
|
+
temp_model.build_from_hash(value)
|
233
|
+
end
|
234
|
+
end
|
235
|
+
|
236
|
+
# Returns the string representation of the object
|
237
|
+
# @return [String] String presentation of the object
|
238
|
+
def to_s
|
239
|
+
to_hash.to_s
|
240
|
+
end
|
241
|
+
|
242
|
+
# to_body is an alias to to_hash (backward compatibility)
|
243
|
+
# @return [Hash] Returns the object in the form of hash
|
244
|
+
def to_body
|
245
|
+
to_hash
|
246
|
+
end
|
247
|
+
|
248
|
+
# Returns the object in the form of hash
|
249
|
+
# @return [Hash] Returns the object in the form of hash
|
250
|
+
def to_hash
|
251
|
+
hash = {}
|
252
|
+
self.class.attribute_map.each_pair do |attr, param|
|
253
|
+
value = self.send(attr)
|
254
|
+
next if value.nil?
|
255
|
+
hash[param] = _to_hash(value)
|
256
|
+
end
|
257
|
+
hash
|
258
|
+
end
|
259
|
+
|
260
|
+
# Outputs non-array value in the form of hash
|
261
|
+
# For object, use to_hash. Otherwise, just return the value
|
262
|
+
# @param [Object] value Any valid value
|
263
|
+
# @return [Hash] Returns the value in the form of hash
|
264
|
+
def _to_hash(value)
|
265
|
+
if value.is_a?(Array)
|
266
|
+
value.compact.map { |v| _to_hash(v) }
|
267
|
+
elsif value.is_a?(Hash)
|
268
|
+
{}.tap do |hash|
|
269
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
270
|
+
end
|
271
|
+
elsif value.respond_to? :to_hash
|
272
|
+
value.to_hash
|
273
|
+
else
|
274
|
+
value
|
275
|
+
end
|
276
|
+
end
|
277
|
+
|
278
|
+
end
|
279
|
+
end
|
@@ -64,7 +64,6 @@ module DocuSign_Click
|
|
64
64
|
# User agreement status. One of: - `created` - `agreed` - `declined`
|
65
65
|
attr_accessor :status
|
66
66
|
|
67
|
-
# This property specifies the custom style provided when the agreement was created by [customizing the template appearance][]. [customizing the template appearance]: /docs/click-api/click101/customize-elastic-template-appearance/
|
68
67
|
attr_accessor :style
|
69
68
|
|
70
69
|
# The human-readable semver version string.
|
@@ -123,7 +122,7 @@ module DocuSign_Click
|
|
123
122
|
:'return_url' => :'String',
|
124
123
|
:'settings' => :'DisplaySettings',
|
125
124
|
:'status' => :'String',
|
126
|
-
:'style' => :'
|
125
|
+
:'style' => :'UserAgreementResponseStyle',
|
127
126
|
:'version' => :'String',
|
128
127
|
:'version_id' => :'String',
|
129
128
|
:'version_number' => :'Integer'
|
@@ -213,9 +212,7 @@ module DocuSign_Click
|
|
213
212
|
end
|
214
213
|
|
215
214
|
if attributes.has_key?(:'style')
|
216
|
-
|
217
|
-
self.style = value
|
218
|
-
end
|
215
|
+
self.style = attributes[:'style']
|
219
216
|
end
|
220
217
|
|
221
218
|
if attributes.has_key?(:'version')
|
@@ -0,0 +1,279 @@
|
|
1
|
+
=begin
|
2
|
+
#DocuSign Click API
|
3
|
+
|
4
|
+
#Elastic signing (also known as DocuSign Click) lets you capture consent to standard agreement terms with a single click: terms and conditions, terms of service, terms of use, privacy policies, and more. The Click API lets you include this customizable elastic template solution in your DocuSign integrations.
|
5
|
+
|
6
|
+
OpenAPI spec version: v1
|
7
|
+
Contact: devcenter@docusign.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module DocuSign_Click
|
15
|
+
# This property specifies the custom style provided when the agreement was created by [customizing the template appearance][]. [customizing the template appearance]: /docs/click-api/click101/customize-elastic-template-appearance/
|
16
|
+
class UserAgreementResponseStyle
|
17
|
+
# Control the display of the Agree button.
|
18
|
+
attr_accessor :agree_button
|
19
|
+
|
20
|
+
# Control the display of the agreement statement.
|
21
|
+
attr_accessor :agreement_statement
|
22
|
+
|
23
|
+
# Control the overall clickwrap container and inherited styles such as font.
|
24
|
+
attr_accessor :container
|
25
|
+
|
26
|
+
# Control the display of the disclosure link.
|
27
|
+
attr_accessor :disclosure_link
|
28
|
+
|
29
|
+
# Control the display of the agreement statement.
|
30
|
+
attr_accessor :document_link
|
31
|
+
|
32
|
+
# Control the display of the header.
|
33
|
+
attr_accessor :header
|
34
|
+
|
35
|
+
# Control the scrolling of the document either by browser or by a scrollbar in the clickwrap shell. Can only be applied if the clickwrap `format` is `inline`.
|
36
|
+
attr_accessor :scroll_control
|
37
|
+
|
38
|
+
class EnumAttributeValidator
|
39
|
+
attr_reader :datatype
|
40
|
+
attr_reader :allowable_values
|
41
|
+
|
42
|
+
def initialize(datatype, allowable_values)
|
43
|
+
@allowable_values = allowable_values.map do |value|
|
44
|
+
case datatype.to_s
|
45
|
+
when /Integer/i
|
46
|
+
value.to_i
|
47
|
+
when /Float/i
|
48
|
+
value.to_f
|
49
|
+
else
|
50
|
+
value
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
def valid?(value)
|
56
|
+
!value || allowable_values.include?(value)
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
61
|
+
def self.attribute_map
|
62
|
+
{
|
63
|
+
:'agree_button' => :'agreeButton',
|
64
|
+
:'agreement_statement' => :'agreementStatement',
|
65
|
+
:'container' => :'container',
|
66
|
+
:'disclosure_link' => :'disclosureLink',
|
67
|
+
:'document_link' => :'documentLink',
|
68
|
+
:'header' => :'header',
|
69
|
+
:'scroll_control' => :'scrollControl'
|
70
|
+
}
|
71
|
+
end
|
72
|
+
|
73
|
+
# Attribute type mapping.
|
74
|
+
def self.swagger_types
|
75
|
+
{
|
76
|
+
:'agree_button' => :'AgreeButtonStyles',
|
77
|
+
:'agreement_statement' => :'AgreementStatementStyles',
|
78
|
+
:'container' => :'ContainerStyles',
|
79
|
+
:'disclosure_link' => :'DisclosureLinkStyles',
|
80
|
+
:'document_link' => :'DocumentLinkStyles',
|
81
|
+
:'header' => :'HeaderStyles',
|
82
|
+
:'scroll_control' => :'String'
|
83
|
+
}
|
84
|
+
end
|
85
|
+
|
86
|
+
# Initializes the object
|
87
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
88
|
+
def initialize(attributes = {})
|
89
|
+
return unless attributes.is_a?(Hash)
|
90
|
+
|
91
|
+
# convert string to symbol for hash key
|
92
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
93
|
+
|
94
|
+
if attributes.has_key?(:'agreeButton')
|
95
|
+
self.agree_button = attributes[:'agreeButton']
|
96
|
+
end
|
97
|
+
|
98
|
+
if attributes.has_key?(:'agreementStatement')
|
99
|
+
self.agreement_statement = attributes[:'agreementStatement']
|
100
|
+
end
|
101
|
+
|
102
|
+
if attributes.has_key?(:'container')
|
103
|
+
self.container = attributes[:'container']
|
104
|
+
end
|
105
|
+
|
106
|
+
if attributes.has_key?(:'disclosureLink')
|
107
|
+
self.disclosure_link = attributes[:'disclosureLink']
|
108
|
+
end
|
109
|
+
|
110
|
+
if attributes.has_key?(:'documentLink')
|
111
|
+
self.document_link = attributes[:'documentLink']
|
112
|
+
end
|
113
|
+
|
114
|
+
if attributes.has_key?(:'header')
|
115
|
+
self.header = attributes[:'header']
|
116
|
+
end
|
117
|
+
|
118
|
+
if attributes.has_key?(:'scrollControl')
|
119
|
+
self.scroll_control = attributes[:'scrollControl']
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
124
|
+
# @return Array for valid properties with the reasons
|
125
|
+
def list_invalid_properties
|
126
|
+
invalid_properties = Array.new
|
127
|
+
invalid_properties
|
128
|
+
end
|
129
|
+
|
130
|
+
# Check to see if the all the properties in the model are valid
|
131
|
+
# @return true if the model is valid
|
132
|
+
def valid?
|
133
|
+
scroll_control_validator = EnumAttributeValidator.new('String', ['browser', 'fill_parent'])
|
134
|
+
return false unless scroll_control_validator.valid?(@scroll_control)
|
135
|
+
true
|
136
|
+
end
|
137
|
+
|
138
|
+
# Custom attribute writer method checking allowed values (enum).
|
139
|
+
# @param [Object] scroll_control Object to be assigned
|
140
|
+
def scroll_control=(scroll_control)
|
141
|
+
validator = EnumAttributeValidator.new('String', ['browser', 'fill_parent'])
|
142
|
+
unless validator.valid?(scroll_control)
|
143
|
+
fail ArgumentError, 'invalid value for "scroll_control", must be one of #{validator.allowable_values}.'
|
144
|
+
end
|
145
|
+
@scroll_control = scroll_control
|
146
|
+
end
|
147
|
+
|
148
|
+
# Checks equality by comparing each attribute.
|
149
|
+
# @param [Object] Object to be compared
|
150
|
+
def ==(o)
|
151
|
+
return true if self.equal?(o)
|
152
|
+
self.class == o.class &&
|
153
|
+
agree_button == o.agree_button &&
|
154
|
+
agreement_statement == o.agreement_statement &&
|
155
|
+
container == o.container &&
|
156
|
+
disclosure_link == o.disclosure_link &&
|
157
|
+
document_link == o.document_link &&
|
158
|
+
header == o.header &&
|
159
|
+
scroll_control == o.scroll_control
|
160
|
+
end
|
161
|
+
|
162
|
+
# @see the `==` method
|
163
|
+
# @param [Object] Object to be compared
|
164
|
+
def eql?(o)
|
165
|
+
self == o
|
166
|
+
end
|
167
|
+
|
168
|
+
# Calculates hash code according to all attributes.
|
169
|
+
# @return [Fixnum] Hash code
|
170
|
+
def hash
|
171
|
+
[agree_button, agreement_statement, container, disclosure_link, document_link, header, scroll_control].hash
|
172
|
+
end
|
173
|
+
|
174
|
+
# Builds the object from hash
|
175
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
176
|
+
# @return [Object] Returns the model itself
|
177
|
+
def build_from_hash(attributes)
|
178
|
+
return nil unless attributes.is_a?(Hash)
|
179
|
+
self.class.swagger_types.each_pair do |key, type|
|
180
|
+
if type =~ /\AArray<(.*)>/i
|
181
|
+
# check to ensure the input is an array given that the attribute
|
182
|
+
# is documented as an array but the input is not
|
183
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
184
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
185
|
+
end
|
186
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
187
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
188
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
189
|
+
end
|
190
|
+
|
191
|
+
self
|
192
|
+
end
|
193
|
+
|
194
|
+
# Deserializes the data based on type
|
195
|
+
# @param string type Data type
|
196
|
+
# @param string value Value to be deserialized
|
197
|
+
# @return [Object] Deserialized data
|
198
|
+
def _deserialize(type, value)
|
199
|
+
case type.to_sym
|
200
|
+
when :DateTime
|
201
|
+
DateTime.parse(value)
|
202
|
+
when :Date
|
203
|
+
Date.parse(value)
|
204
|
+
when :String
|
205
|
+
value.to_s
|
206
|
+
when :Integer
|
207
|
+
value.to_i
|
208
|
+
when :Float
|
209
|
+
value.to_f
|
210
|
+
when :BOOLEAN
|
211
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
212
|
+
true
|
213
|
+
else
|
214
|
+
false
|
215
|
+
end
|
216
|
+
when :Object
|
217
|
+
# generic object (usually a Hash), return directly
|
218
|
+
value
|
219
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
220
|
+
inner_type = Regexp.last_match[:inner_type]
|
221
|
+
value.map { |v| _deserialize(inner_type, v) }
|
222
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
223
|
+
k_type = Regexp.last_match[:k_type]
|
224
|
+
v_type = Regexp.last_match[:v_type]
|
225
|
+
{}.tap do |hash|
|
226
|
+
value.each do |k, v|
|
227
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
228
|
+
end
|
229
|
+
end
|
230
|
+
else # model
|
231
|
+
temp_model = DocuSign_Click.const_get(type).new
|
232
|
+
temp_model.build_from_hash(value)
|
233
|
+
end
|
234
|
+
end
|
235
|
+
|
236
|
+
# Returns the string representation of the object
|
237
|
+
# @return [String] String presentation of the object
|
238
|
+
def to_s
|
239
|
+
to_hash.to_s
|
240
|
+
end
|
241
|
+
|
242
|
+
# to_body is an alias to to_hash (backward compatibility)
|
243
|
+
# @return [Hash] Returns the object in the form of hash
|
244
|
+
def to_body
|
245
|
+
to_hash
|
246
|
+
end
|
247
|
+
|
248
|
+
# Returns the object in the form of hash
|
249
|
+
# @return [Hash] Returns the object in the form of hash
|
250
|
+
def to_hash
|
251
|
+
hash = {}
|
252
|
+
self.class.attribute_map.each_pair do |attr, param|
|
253
|
+
value = self.send(attr)
|
254
|
+
next if value.nil?
|
255
|
+
hash[param] = _to_hash(value)
|
256
|
+
end
|
257
|
+
hash
|
258
|
+
end
|
259
|
+
|
260
|
+
# Outputs non-array value in the form of hash
|
261
|
+
# For object, use to_hash. Otherwise, just return the value
|
262
|
+
# @param [Object] value Any valid value
|
263
|
+
# @return [Hash] Returns the value in the form of hash
|
264
|
+
def _to_hash(value)
|
265
|
+
if value.is_a?(Array)
|
266
|
+
value.compact.map { |v| _to_hash(v) }
|
267
|
+
elsif value.is_a?(Hash)
|
268
|
+
{}.tap do |hash|
|
269
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
270
|
+
end
|
271
|
+
elsif value.respond_to? :to_hash
|
272
|
+
value.to_hash
|
273
|
+
else
|
274
|
+
value
|
275
|
+
end
|
276
|
+
end
|
277
|
+
|
278
|
+
end
|
279
|
+
end
|
data/lib/docusign_click.rb
CHANGED
@@ -19,6 +19,9 @@ require 'docusign_click/configuration'
|
|
19
19
|
require 'docusign_click/client/auth/oauth'
|
20
20
|
|
21
21
|
# Models
|
22
|
+
require 'docusign_click/models/agree_button_styles'
|
23
|
+
require 'docusign_click/models/agreement_statement_styles'
|
24
|
+
require 'docusign_click/models/base_agree_button_styles'
|
22
25
|
require 'docusign_click/models/bulk_clickwrap_request'
|
23
26
|
require 'docusign_click/models/clickwrap_agreements_response'
|
24
27
|
require 'docusign_click/models/clickwrap_delete_response'
|
@@ -33,14 +36,20 @@ require 'docusign_click/models/clickwrap_versions_delete_response'
|
|
33
36
|
require 'docusign_click/models/clickwrap_versions_paged_response'
|
34
37
|
require 'docusign_click/models/clickwrap_versions_response'
|
35
38
|
require 'docusign_click/models/clickwraps_delete_response'
|
39
|
+
require 'docusign_click/models/container_styles'
|
36
40
|
require 'docusign_click/models/data_field'
|
41
|
+
require 'docusign_click/models/disclosure_link_styles'
|
37
42
|
require 'docusign_click/models/display_settings'
|
38
43
|
require 'docusign_click/models/document'
|
44
|
+
require 'docusign_click/models/document_link_styles'
|
45
|
+
require 'docusign_click/models/document_link_styles_focus'
|
39
46
|
require 'docusign_click/models/error_details'
|
47
|
+
require 'docusign_click/models/header_styles'
|
40
48
|
require 'docusign_click/models/service_information'
|
41
49
|
require 'docusign_click/models/service_version'
|
42
50
|
require 'docusign_click/models/user_agreement_request'
|
43
51
|
require 'docusign_click/models/user_agreement_response'
|
52
|
+
require 'docusign_click/models/user_agreement_response_style'
|
44
53
|
|
45
54
|
# APIs
|
46
55
|
require 'docusign_click/api/accounts_api'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: docusign_click
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- DocuSign
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-06-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jwt
|
@@ -294,6 +294,9 @@ files:
|
|
294
294
|
- lib/docusign_click/client/api_error.rb
|
295
295
|
- lib/docusign_click/client/auth/oauth.rb
|
296
296
|
- lib/docusign_click/configuration.rb
|
297
|
+
- lib/docusign_click/models/agree_button_styles.rb
|
298
|
+
- lib/docusign_click/models/agreement_statement_styles.rb
|
299
|
+
- lib/docusign_click/models/base_agree_button_styles.rb
|
297
300
|
- lib/docusign_click/models/bulk_clickwrap_request.rb
|
298
301
|
- lib/docusign_click/models/clickwrap_agreements_response.rb
|
299
302
|
- lib/docusign_click/models/clickwrap_delete_response.rb
|
@@ -308,14 +311,19 @@ files:
|
|
308
311
|
- lib/docusign_click/models/clickwrap_versions_paged_response.rb
|
309
312
|
- lib/docusign_click/models/clickwrap_versions_response.rb
|
310
313
|
- lib/docusign_click/models/clickwraps_delete_response.rb
|
314
|
+
- lib/docusign_click/models/container_styles.rb
|
311
315
|
- lib/docusign_click/models/conversion_document.rb
|
312
316
|
- lib/docusign_click/models/data_field.rb
|
317
|
+
- lib/docusign_click/models/disclosure_link_styles.rb
|
313
318
|
- lib/docusign_click/models/display_settings.rb
|
314
319
|
- lib/docusign_click/models/document.rb
|
315
320
|
- lib/docusign_click/models/document_conversion_request.rb
|
316
321
|
- lib/docusign_click/models/document_conversion_response.rb
|
317
322
|
- lib/docusign_click/models/document_data.rb
|
323
|
+
- lib/docusign_click/models/document_link_styles.rb
|
324
|
+
- lib/docusign_click/models/document_link_styles_focus.rb
|
318
325
|
- lib/docusign_click/models/error_details.rb
|
326
|
+
- lib/docusign_click/models/header_styles.rb
|
319
327
|
- lib/docusign_click/models/html_result.rb
|
320
328
|
- lib/docusign_click/models/recipient_copy_request.rb
|
321
329
|
- lib/docusign_click/models/service_information.rb
|
@@ -323,6 +331,7 @@ files:
|
|
323
331
|
- lib/docusign_click/models/update_agreement_request.rb
|
324
332
|
- lib/docusign_click/models/user_agreement_request.rb
|
325
333
|
- lib/docusign_click/models/user_agreement_response.rb
|
334
|
+
- lib/docusign_click/models/user_agreement_response_style.rb
|
326
335
|
- lib/docusign_click/version.rb
|
327
336
|
- runLinter.sh
|
328
337
|
- tests/Gemfile
|