Method: Composio::APIKeyResDTO#list_invalid_properties
- Defined in:
- lib/composio/models/api_key_res_dto.rb
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 |
# File 'lib/composio/models/api_key_res_dto.rb', line 127 def list_invalid_properties invalid_properties = Array.new if @id.nil? invalid_properties.push('invalid value for "id", id cannot be nil.') end if @name.nil? invalid_properties.push('invalid value for "name", name cannot be nil.') end if @created_at.nil? invalid_properties.push('invalid value for "created_at", created_at cannot be nil.') end pattern = Regexp.new(/\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d.\d+Z?/) if @created_at !~ pattern invalid_properties.push("invalid value for \"created_at\", must conform to the pattern #{pattern}.") end if @updated_at.nil? invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.') end pattern = Regexp.new(/\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d.\d+Z?/) if @updated_at !~ pattern invalid_properties.push("invalid value for \"updated_at\", must conform to the pattern #{pattern}.") end if @key.nil? invalid_properties.push('invalid value for "key", key cannot be nil.') end if @is_hidden.nil? invalid_properties.push('invalid value for "is_hidden", is_hidden cannot be nil.') end pattern = Regexp.new(/\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d.\d+Z?/) if !@last_used.nil? && @last_used !~ pattern invalid_properties.push("invalid value for \"last_used\", must conform to the pattern #{pattern}.") end if @member.nil? invalid_properties.push('invalid value for "member", member cannot be nil.') end invalid_properties end |