Class: VoiceBase::Request::HashPart

Inherits:
TextPart
  • Object
show all
Defined in:
lib/voicebase/request/hash_part.rb

Instance Attribute Summary

Attributes inherited from TextPart

#body, #name

Instance Method Summary collapse

Methods inherited from TextPart

#multipart

Constructor Details

#initialize(name:, hash:) ⇒ HashPart

Returns a new instance of HashPart.



7
8
9
10
# File 'lib/voicebase/request/hash_part.rb', line 7

def initialize(name:, hash:)
  @name = name
  @body = ::JSON.dump(hash)
end