The following request is made to /v2.0/conversion
.
We are using Faraday on the Rails API server.
file = Faraday::Multipart::FilePart.new(file_path, file_name)
connection = Faraday.new(url: "https://api.groupdocs.cloud") do |builder|
builder.request :multipart
end
res = connection.post("/v2.0/conversion") do |req|
req.headers["Authorization"] = "Bearer #{access_token}"
req.body = {
"format": "pdf",.
"File": file, }
}
end
Why do I get 415 for the above request?