Class: PostEnvironmentsResponse401
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- PostEnvironmentsResponse401
- Defined in:
- lib/schemas.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.from_dynamic!(d) ⇒ Object
23310 23311 23312 23313 23314 23315 |
# File 'lib/schemas.rb', line 23310 def self.from_dynamic!(d) d = Types::Hash[d] new( error: d["error"] ? PostEnvironmentsResponse401Error.from_dynamic!(d["error"]) : nil, ) end |
.from_json!(json) ⇒ Object
23317 23318 23319 |
# File 'lib/schemas.rb', line 23317 def self.from_json!(json) from_dynamic!(JSON.parse(json)) end |
Instance Method Details
#to_dynamic ⇒ Object
23321 23322 23323 23324 23325 |
# File 'lib/schemas.rb', line 23321 def to_dynamic { "error" => error&.to_dynamic, } end |
#to_json(options = nil) ⇒ Object
23327 23328 23329 |
# File 'lib/schemas.rb', line 23327 def to_json( = nil) JSON.generate(to_dynamic, ) end |