I want to POST request, using Ruby gem Faraday. Content-Type is "application/pdf".
my code is below.
client = Faraday.new(endpoint) do |client|
client.request :retry
client.headers['Content-Type'] = "application/pdf"
client.headers['Authorization'] = auth_token
client.adapter Faraday.default_adapter
end
response = client.public_send(:post, endpoint, params)
but, I got Error.
undefined method `bytesize' for {:title=>"0722 14 ID:14"}:Hash
Please Help me.