connectwise-ruby-sdk 1.0.1 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +13 -18
  3. data/connectwise-ruby-sdk.gemspec +2 -1
  4. data/lib/connectwise-ruby-sdk/api/documents_api.rb +8 -8
  5. data/lib/connectwise-ruby-sdk/api_client.rb +1 -1
  6. data/lib/connectwise-ruby-sdk/models/activity.rb +27 -15
  7. data/lib/connectwise-ruby-sdk/models/activity_status.rb +11 -3
  8. data/lib/connectwise-ruby-sdk/models/activity_type.rb +11 -3
  9. data/lib/connectwise-ruby-sdk/models/addition.rb +16 -12
  10. data/lib/connectwise-ruby-sdk/models/adjustment.rb +8 -6
  11. data/lib/connectwise-ruby-sdk/models/agreement.rb +43 -27
  12. data/lib/connectwise-ruby-sdk/models/agreement_type.rb +27 -15
  13. data/lib/connectwise-ruby-sdk/models/audit_trail_entry_insert_request.rb +11 -3
  14. data/lib/connectwise-ruby-sdk/models/batch.rb +11 -3
  15. data/lib/connectwise-ruby-sdk/models/board.rb +11 -3
  16. data/lib/connectwise-ruby-sdk/models/callback_entry.rb +8 -6
  17. data/lib/connectwise-ruby-sdk/models/campaign.rb +11 -3
  18. data/lib/connectwise-ruby-sdk/models/campaign_audit.rb +46 -20
  19. data/lib/connectwise-ruby-sdk/models/campaign_status.rb +11 -3
  20. data/lib/connectwise-ruby-sdk/models/campaign_sub_type.rb +11 -3
  21. data/lib/connectwise-ruby-sdk/models/campaign_type.rb +11 -3
  22. data/lib/connectwise-ruby-sdk/models/catalog_item.rb +57 -27
  23. data/lib/connectwise-ruby-sdk/models/category.rb +27 -15
  24. data/lib/connectwise-ruby-sdk/models/code.rb +11 -3
  25. data/lib/connectwise-ruby-sdk/models/company.rb +185 -123
  26. data/lib/connectwise-ruby-sdk/models/company_management_summary.rb +11 -3
  27. data/lib/connectwise-ruby-sdk/models/company_site.rb +67 -45
  28. data/lib/connectwise-ruby-sdk/models/company_status.rb +19 -9
  29. data/lib/connectwise-ruby-sdk/models/company_type.rb +11 -3
  30. data/lib/connectwise-ruby-sdk/models/configuration.rb +131 -93
  31. data/lib/connectwise-ruby-sdk/models/configuration_status.rb +11 -3
  32. data/lib/connectwise-ruby-sdk/models/configuration_type.rb +11 -3
  33. data/lib/connectwise-ruby-sdk/models/configuration_type_question.rb +24 -10
  34. data/lib/connectwise-ruby-sdk/models/connect_wise_hosted_setup.rb +30 -12
  35. data/lib/connectwise-ruby-sdk/models/contact.rb +128 -88
  36. data/lib/connectwise-ruby-sdk/models/contact_communication.rb +19 -9
  37. data/lib/connectwise-ruby-sdk/models/contact_communication_item.rb +19 -9
  38. data/lib/connectwise-ruby-sdk/models/contact_department.rb +11 -3
  39. data/lib/connectwise-ruby-sdk/models/contact_relationship.rb +11 -3
  40. data/lib/connectwise-ruby-sdk/models/contact_type.rb +11 -3
  41. data/lib/connectwise-ruby-sdk/models/currency.rb +35 -21
  42. data/lib/connectwise-ruby-sdk/models/expense_type.rb +11 -3
  43. data/lib/connectwise-ruby-sdk/models/forecast.rb +8 -6
  44. data/lib/connectwise-ruby-sdk/models/form_submitted.rb +11 -3
  45. data/lib/connectwise-ruby-sdk/models/group.rb +8 -6
  46. data/lib/connectwise-ruby-sdk/models/integrator_login.rb +118 -78
  47. data/lib/connectwise-ruby-sdk/models/invoice.rb +32 -24
  48. data/lib/connectwise-ruby-sdk/models/item.rb +11 -3
  49. data/lib/connectwise-ruby-sdk/models/link.rb +19 -9
  50. data/lib/connectwise-ruby-sdk/models/link_clicked.rb +11 -3
  51. data/lib/connectwise-ruby-sdk/models/location.rb +11 -3
  52. data/lib/connectwise-ruby-sdk/models/manufacturer.rb +11 -3
  53. data/lib/connectwise-ruby-sdk/models/marketing_contact.rb +8 -6
  54. data/lib/connectwise-ruby-sdk/models/member.rb +129 -81
  55. data/lib/connectwise-ruby-sdk/models/menu_entry.rb +30 -12
  56. data/lib/connectwise-ruby-sdk/models/opportunity.rb +27 -15
  57. data/lib/connectwise-ruby-sdk/models/opportunity_rating.rb +11 -3
  58. data/lib/connectwise-ruby-sdk/models/opportunity_status.rb +11 -3
  59. data/lib/connectwise-ruby-sdk/models/opportunity_type.rb +11 -3
  60. data/lib/connectwise-ruby-sdk/models/order.rb +8 -6
  61. data/lib/connectwise-ruby-sdk/models/order_status.rb +11 -3
  62. data/lib/connectwise-ruby-sdk/models/pricing_schedule.rb +11 -3
  63. data/lib/connectwise-ruby-sdk/models/priority.rb +22 -6
  64. data/lib/connectwise-ruby-sdk/models/product_item.rb +40 -30
  65. data/lib/connectwise-ruby-sdk/models/product_type.rb +11 -3
  66. data/lib/connectwise-ruby-sdk/models/project.rb +27 -15
  67. data/lib/connectwise-ruby-sdk/models/project_phase.rb +19 -9
  68. data/lib/connectwise-ruby-sdk/models/purchase_order.rb +32 -24
  69. data/lib/connectwise-ruby-sdk/models/purchase_order_line_item.rb +59 -39
  70. data/lib/connectwise-ruby-sdk/models/schedule_entry.rb +8 -6
  71. data/lib/connectwise-ruby-sdk/models/schedule_status.rb +11 -3
  72. data/lib/connectwise-ruby-sdk/models/schedule_type.rb +22 -6
  73. data/lib/connectwise-ruby-sdk/models/shipment_method.rb +11 -3
  74. data/lib/connectwise-ruby-sdk/models/source.rb +11 -3
  75. data/lib/connectwise-ruby-sdk/models/status.rb +11 -3
  76. data/lib/connectwise-ruby-sdk/models/sub_category.rb +11 -3
  77. data/lib/connectwise-ruby-sdk/models/sub_type.rb +11 -3
  78. data/lib/connectwise-ruby-sdk/models/survey.rb +35 -21
  79. data/lib/connectwise-ruby-sdk/models/survey_question.rb +11 -3
  80. data/lib/connectwise-ruby-sdk/models/survey_question_option.rb +11 -3
  81. data/lib/connectwise-ruby-sdk/models/task.rb +13 -7
  82. data/lib/connectwise-ruby-sdk/models/team.rb +11 -3
  83. data/lib/connectwise-ruby-sdk/models/ticket.rb +115 -81
  84. data/lib/connectwise-ruby-sdk/models/type.rb +11 -3
  85. data/lib/connectwise-ruby-sdk/models/unit_of_measure.rb +19 -9
  86. data/lib/connectwise-ruby-sdk/models/user_defined_field.rb +52 -22
  87. data/lib/connectwise-ruby-sdk/models/user_defined_field_option.rb +11 -3
  88. data/lib/connectwise-ruby-sdk/version.rb +1 -1
  89. data/spec/api_client_spec.rb +3 -2
  90. data/spec/configuration_spec.rb +1 -0
  91. data/spec/spec_helper.rb +1 -0
  92. metadata +2 -3
  93. data/git_push.sh +0 -67
@@ -147,6 +147,19 @@ module Connectwise
147
147
  # @return Array for valid properies with the reasons
148
148
  def list_invalid_properties
149
149
  invalid_properties = Array.new
150
+ if @value.nil?
151
+ invalid_properties.push("invalid value for 'value', value cannot be nil.")
152
+ end
153
+
154
+ if @value.to_s.length > 250
155
+ invalid_properties.push("invalid value for 'value', the character length must be smaller than or equal to 250.")
156
+ end
157
+
158
+
159
+ if !@extension.nil? && @extension.to_s.length > 15
160
+ invalid_properties.push("invalid value for 'extension', the character length must be smaller than or equal to 15.")
161
+ end
162
+
150
163
  return invalid_properties
151
164
  end
152
165
 
@@ -155,8 +168,8 @@ module Connectwise
155
168
  def valid?
156
169
  return false if @type.nil?
157
170
  return false if @value.nil?
158
- return false if @value.to_s.length <
159
- return false if @extension.to_s.length <
171
+ return false if @value.to_s.length > 250
172
+ return false if !@extension.nil? && @extension.to_s.length > 15
160
173
  communication_type_validator = EnumAttributeValidator.new('String', ["Phone", "Fax", "Email"])
161
174
  return false unless communication_type_validator.valid?(@communication_type)
162
175
  return true
@@ -169,8 +182,8 @@ module Connectwise
169
182
  fail ArgumentError, "value cannot be nil"
170
183
  end
171
184
 
172
- if value.to_s.length <
173
- fail ArgumentError, "invalid value for 'value', the character length must be great than or equal to ."
185
+ if value.to_s.length > 250
186
+ fail ArgumentError, "invalid value for 'value', the character length must be smaller than or equal to 250."
174
187
  end
175
188
 
176
189
  @value = value
@@ -179,12 +192,9 @@ module Connectwise
179
192
  # Custom attribute writer method with validation
180
193
  # @param [Object] extension Value to be assigned
181
194
  def extension=(extension)
182
- if extension.nil?
183
- fail ArgumentError, "extension cannot be nil"
184
- end
185
195
 
186
- if extension.to_s.length <
187
- fail ArgumentError, "invalid value for 'extension', the character length must be great than or equal to ."
196
+ if !extension.nil? && extension.to_s.length > 15
197
+ fail ArgumentError, "invalid value for 'extension', the character length must be smaller than or equal to 15."
188
198
  end
189
199
 
190
200
  @extension = extension
@@ -122,6 +122,19 @@ module Connectwise
122
122
  # @return Array for valid properies with the reasons
123
123
  def list_invalid_properties
124
124
  invalid_properties = Array.new
125
+ if @value.nil?
126
+ invalid_properties.push("invalid value for 'value', value cannot be nil.")
127
+ end
128
+
129
+ if @value.to_s.length > 250
130
+ invalid_properties.push("invalid value for 'value', the character length must be smaller than or equal to 250.")
131
+ end
132
+
133
+
134
+ if !@extension.nil? && @extension.to_s.length > 15
135
+ invalid_properties.push("invalid value for 'extension', the character length must be smaller than or equal to 15.")
136
+ end
137
+
125
138
  return invalid_properties
126
139
  end
127
140
 
@@ -130,8 +143,8 @@ module Connectwise
130
143
  def valid?
131
144
  return false if @type.nil?
132
145
  return false if @value.nil?
133
- return false if @value.to_s.length <
134
- return false if @extension.to_s.length <
146
+ return false if @value.to_s.length > 250
147
+ return false if !@extension.nil? && @extension.to_s.length > 15
135
148
  communication_type_validator = EnumAttributeValidator.new('String', ["Phone", "Fax", "Email"])
136
149
  return false unless communication_type_validator.valid?(@communication_type)
137
150
  return true
@@ -144,8 +157,8 @@ module Connectwise
144
157
  fail ArgumentError, "value cannot be nil"
145
158
  end
146
159
 
147
- if value.to_s.length <
148
- fail ArgumentError, "invalid value for 'value', the character length must be great than or equal to ."
160
+ if value.to_s.length > 250
161
+ fail ArgumentError, "invalid value for 'value', the character length must be smaller than or equal to 250."
149
162
  end
150
163
 
151
164
  @value = value
@@ -154,12 +167,9 @@ module Connectwise
154
167
  # Custom attribute writer method with validation
155
168
  # @param [Object] extension Value to be assigned
156
169
  def extension=(extension)
157
- if extension.nil?
158
- fail ArgumentError, "extension cannot be nil"
159
- end
160
170
 
161
- if extension.to_s.length <
162
- fail ArgumentError, "invalid value for 'extension', the character length must be great than or equal to ."
171
+ if !extension.nil? && extension.to_s.length > 15
172
+ fail ArgumentError, "invalid value for 'extension', the character length must be smaller than or equal to 15."
163
173
  end
164
174
 
165
175
  @extension = extension
@@ -78,6 +78,14 @@ module Connectwise
78
78
  # @return Array for valid properies with the reasons
79
79
  def list_invalid_properties
80
80
  invalid_properties = Array.new
81
+ if @name.nil?
82
+ invalid_properties.push("invalid value for 'name', name cannot be nil.")
83
+ end
84
+
85
+ if @name.to_s.length > 30
86
+ invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 30.")
87
+ end
88
+
81
89
  return invalid_properties
82
90
  end
83
91
 
@@ -85,7 +93,7 @@ module Connectwise
85
93
  # @return true if the model is valid
86
94
  def valid?
87
95
  return false if @name.nil?
88
- return false if @name.to_s.length <
96
+ return false if @name.to_s.length > 30
89
97
  return true
90
98
  end
91
99
 
@@ -96,8 +104,8 @@ module Connectwise
96
104
  fail ArgumentError, "name cannot be nil"
97
105
  end
98
106
 
99
- if name.to_s.length <
100
- fail ArgumentError, "invalid value for 'name', the character length must be great than or equal to ."
107
+ if name.to_s.length > 30
108
+ fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 30."
101
109
  end
102
110
 
103
111
  @name = name
@@ -78,6 +78,14 @@ module Connectwise
78
78
  # @return Array for valid properies with the reasons
79
79
  def list_invalid_properties
80
80
  invalid_properties = Array.new
81
+ if @name.nil?
82
+ invalid_properties.push("invalid value for 'name', name cannot be nil.")
83
+ end
84
+
85
+ if @name.to_s.length > 50
86
+ invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
87
+ end
88
+
81
89
  return invalid_properties
82
90
  end
83
91
 
@@ -85,7 +93,7 @@ module Connectwise
85
93
  # @return true if the model is valid
86
94
  def valid?
87
95
  return false if @name.nil?
88
- return false if @name.to_s.length <
96
+ return false if @name.to_s.length > 50
89
97
  return true
90
98
  end
91
99
 
@@ -96,8 +104,8 @@ module Connectwise
96
104
  fail ArgumentError, "name cannot be nil"
97
105
  end
98
106
 
99
- if name.to_s.length <
100
- fail ArgumentError, "invalid value for 'name', the character length must be great than or equal to ."
107
+ if name.to_s.length > 50
108
+ fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
101
109
  end
102
110
 
103
111
  @name = name
@@ -86,6 +86,14 @@ module Connectwise
86
86
  # @return Array for valid properies with the reasons
87
87
  def list_invalid_properties
88
88
  invalid_properties = Array.new
89
+ if @description.nil?
90
+ invalid_properties.push("invalid value for 'description', description cannot be nil.")
91
+ end
92
+
93
+ if @description.to_s.length > 50
94
+ invalid_properties.push("invalid value for 'description', the character length must be smaller than or equal to 50.")
95
+ end
96
+
89
97
  return invalid_properties
90
98
  end
91
99
 
@@ -93,7 +101,7 @@ module Connectwise
93
101
  # @return true if the model is valid
94
102
  def valid?
95
103
  return false if @description.nil?
96
- return false if @description.to_s.length <
104
+ return false if @description.to_s.length > 50
97
105
  return true
98
106
  end
99
107
 
@@ -104,8 +112,8 @@ module Connectwise
104
112
  fail ArgumentError, "description cannot be nil"
105
113
  end
106
114
 
107
- if description.to_s.length <
108
- fail ArgumentError, "invalid value for 'description', the character length must be great than or equal to ."
115
+ if description.to_s.length > 50
116
+ fail ArgumentError, "invalid value for 'description', the character length must be smaller than or equal to 50."
109
117
  end
110
118
 
111
119
  @description = description
@@ -118,6 +118,29 @@ module Connectwise
118
118
  # @return Array for valid properies with the reasons
119
119
  def list_invalid_properties
120
120
  invalid_properties = Array.new
121
+ if @currency_identifier.nil?
122
+ invalid_properties.push("invalid value for 'currency_identifier', currency_identifier cannot be nil.")
123
+ end
124
+
125
+ if @currency_identifier.to_s.length > 10
126
+ invalid_properties.push("invalid value for 'currency_identifier', the character length must be smaller than or equal to 10.")
127
+ end
128
+
129
+
130
+ if !@name.nil? && @name.to_s.length > 50
131
+ invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
132
+ end
133
+
134
+
135
+ if !@symbol.nil? && @symbol.to_s.length > 10
136
+ invalid_properties.push("invalid value for 'symbol', the character length must be smaller than or equal to 10.")
137
+ end
138
+
139
+
140
+ if !@iso_code.nil? && @iso_code.to_s.length > 3
141
+ invalid_properties.push("invalid value for 'iso_code', the character length must be smaller than or equal to 3.")
142
+ end
143
+
121
144
  return invalid_properties
122
145
  end
123
146
 
@@ -125,10 +148,10 @@ module Connectwise
125
148
  # @return true if the model is valid
126
149
  def valid?
127
150
  return false if @currency_identifier.nil?
128
- return false if @currency_identifier.to_s.length <
129
- return false if @name.to_s.length <
130
- return false if @symbol.to_s.length <
131
- return false if @iso_code.to_s.length <
151
+ return false if @currency_identifier.to_s.length > 10
152
+ return false if !@name.nil? && @name.to_s.length > 50
153
+ return false if !@symbol.nil? && @symbol.to_s.length > 10
154
+ return false if !@iso_code.nil? && @iso_code.to_s.length > 3
132
155
  return true
133
156
  end
134
157
 
@@ -139,8 +162,8 @@ module Connectwise
139
162
  fail ArgumentError, "currency_identifier cannot be nil"
140
163
  end
141
164
 
142
- if currency_identifier.to_s.length <
143
- fail ArgumentError, "invalid value for 'currency_identifier', the character length must be great than or equal to ."
165
+ if currency_identifier.to_s.length > 10
166
+ fail ArgumentError, "invalid value for 'currency_identifier', the character length must be smaller than or equal to 10."
144
167
  end
145
168
 
146
169
  @currency_identifier = currency_identifier
@@ -149,12 +172,9 @@ module Connectwise
149
172
  # Custom attribute writer method with validation
150
173
  # @param [Object] name Value to be assigned
151
174
  def name=(name)
152
- if name.nil?
153
- fail ArgumentError, "name cannot be nil"
154
- end
155
175
 
156
- if name.to_s.length <
157
- fail ArgumentError, "invalid value for 'name', the character length must be great than or equal to ."
176
+ if !name.nil? && name.to_s.length > 50
177
+ fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
158
178
  end
159
179
 
160
180
  @name = name
@@ -163,12 +183,9 @@ module Connectwise
163
183
  # Custom attribute writer method with validation
164
184
  # @param [Object] symbol Value to be assigned
165
185
  def symbol=(symbol)
166
- if symbol.nil?
167
- fail ArgumentError, "symbol cannot be nil"
168
- end
169
186
 
170
- if symbol.to_s.length <
171
- fail ArgumentError, "invalid value for 'symbol', the character length must be great than or equal to ."
187
+ if !symbol.nil? && symbol.to_s.length > 10
188
+ fail ArgumentError, "invalid value for 'symbol', the character length must be smaller than or equal to 10."
172
189
  end
173
190
 
174
191
  @symbol = symbol
@@ -177,12 +194,9 @@ module Connectwise
177
194
  # Custom attribute writer method with validation
178
195
  # @param [Object] iso_code Value to be assigned
179
196
  def iso_code=(iso_code)
180
- if iso_code.nil?
181
- fail ArgumentError, "iso_code cannot be nil"
182
- end
183
197
 
184
- if iso_code.to_s.length <
185
- fail ArgumentError, "invalid value for 'iso_code', the character length must be great than or equal to ."
198
+ if !iso_code.nil? && iso_code.to_s.length > 3
199
+ fail ArgumentError, "invalid value for 'iso_code', the character length must be smaller than or equal to 3."
186
200
  end
187
201
 
188
202
  @iso_code = iso_code
@@ -179,6 +179,14 @@ module Connectwise
179
179
  # @return Array for valid properies with the reasons
180
180
  def list_invalid_properties
181
181
  invalid_properties = Array.new
182
+ if @name.nil?
183
+ invalid_properties.push("invalid value for 'name', name cannot be nil.")
184
+ end
185
+
186
+ if @name.to_s.length > 30
187
+ invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 30.")
188
+ end
189
+
182
190
  return invalid_properties
183
191
  end
184
192
 
@@ -186,7 +194,7 @@ module Connectwise
186
194
  # @return true if the model is valid
187
195
  def valid?
188
196
  return false if @name.nil?
189
- return false if @name.to_s.length <
197
+ return false if @name.to_s.length > 30
190
198
  return false if @amount_caption.nil?
191
199
  return false if @bill_expenses.nil?
192
200
  bill_expenses_validator = EnumAttributeValidator.new('String', ["Billable", "DoNotBill", "NoCharge"])
@@ -204,8 +212,8 @@ module Connectwise
204
212
  fail ArgumentError, "name cannot be nil"
205
213
  end
206
214
 
207
- if name.to_s.length <
208
- fail ArgumentError, "invalid value for 'name', the character length must be great than or equal to ."
215
+ if name.to_s.length > 30
216
+ fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 30."
209
217
  end
210
218
 
211
219
  @name = name
@@ -171,13 +171,18 @@ module Connectwise
171
171
  # @return Array for valid properies with the reasons
172
172
  def list_invalid_properties
173
173
  invalid_properties = Array.new
174
+
175
+ if !@name.nil? && @name.to_s.length > 50
176
+ invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
177
+ end
178
+
174
179
  return invalid_properties
175
180
  end
176
181
 
177
182
  # Check to see if the all the properties in the model are valid
178
183
  # @return true if the model is valid
179
184
  def valid?
180
- return false if @name.to_s.length <
185
+ return false if !@name.nil? && @name.to_s.length > 50
181
186
  return false if @type.nil?
182
187
  type_validator = EnumAttributeValidator.new('String', ["Product", "Service", "Agreement", "Other1", "Other2"])
183
188
  return false unless type_validator.valid?(@type)
@@ -187,12 +192,9 @@ module Connectwise
187
192
  # Custom attribute writer method with validation
188
193
  # @param [Object] name Value to be assigned
189
194
  def name=(name)
190
- if name.nil?
191
- fail ArgumentError, "name cannot be nil"
192
- end
193
195
 
194
- if name.to_s.length <
195
- fail ArgumentError, "invalid value for 'name', the character length must be great than or equal to ."
196
+ if !name.nil? && name.to_s.length > 50
197
+ fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
196
198
  end
197
199
 
198
200
  @name = name
@@ -141,6 +141,14 @@ module Connectwise
141
141
  # @return Array for valid properies with the reasons
142
142
  def list_invalid_properties
143
143
  invalid_properties = Array.new
144
+ if @url.nil?
145
+ invalid_properties.push("invalid value for 'url', url cannot be nil.")
146
+ end
147
+
148
+ if @url.to_s.length > 2083
149
+ invalid_properties.push("invalid value for 'url', the character length must be smaller than or equal to 2083.")
150
+ end
151
+
144
152
  return invalid_properties
145
153
  end
146
154
 
@@ -149,7 +157,7 @@ module Connectwise
149
157
  def valid?
150
158
  return false if @contact_id.nil?
151
159
  return false if @url.nil?
152
- return false if @url.to_s.length <
160
+ return false if @url.to_s.length > 2083
153
161
  return true
154
162
  end
155
163
 
@@ -160,8 +168,8 @@ module Connectwise
160
168
  fail ArgumentError, "url cannot be nil"
161
169
  end
162
170
 
163
- if url.to_s.length <
164
- fail ArgumentError, "invalid value for 'url', the character length must be great than or equal to ."
171
+ if url.to_s.length > 2083
172
+ fail ArgumentError, "invalid value for 'url', the character length must be smaller than or equal to 2083."
165
173
  end
166
174
 
167
175
  @url = url
@@ -102,6 +102,11 @@ module Connectwise
102
102
  # @return Array for valid properies with the reasons
103
103
  def list_invalid_properties
104
104
  invalid_properties = Array.new
105
+
106
+ if !@public_description.nil? && @public_description.to_s.length > 255
107
+ invalid_properties.push("invalid value for 'public_description', the character length must be smaller than or equal to 255.")
108
+ end
109
+
105
110
  return invalid_properties
106
111
  end
107
112
 
@@ -109,19 +114,16 @@ module Connectwise
109
114
  # @return true if the model is valid
110
115
  def valid?
111
116
  return false if @name.nil?
112
- return false if @public_description.to_s.length <
117
+ return false if !@public_description.nil? && @public_description.to_s.length > 255
113
118
  return true
114
119
  end
115
120
 
116
121
  # Custom attribute writer method with validation
117
122
  # @param [Object] public_description Value to be assigned
118
123
  def public_description=(public_description)
119
- if public_description.nil?
120
- fail ArgumentError, "public_description cannot be nil"
121
- end
122
124
 
123
- if public_description.to_s.length <
124
- fail ArgumentError, "invalid value for 'public_description', the character length must be great than or equal to ."
125
+ if !public_description.nil? && public_description.to_s.length > 255
126
+ fail ArgumentError, "invalid value for 'public_description', the character length must be smaller than or equal to 255."
125
127
  end
126
128
 
127
129
  @public_description = public_description