uploadcare / uploadcare-ruby

Ruby API client that handles uploads and further operations with files by wrapping Uploadcare Upload and REST APIs.
https://uploadcare.com
MIT License
39 stars 28 forks source link

Fix File, Webhook client request bodies. Add missing require 'api_struct' #75

Closed dmitrijivanchenko closed 3 years ago

dmitrijivanchenko commented 3 years ago

Description

1. Fix request params: replace key :body with :content because the request is expecting :content, not :body in

2. Fix body parameter:

3. Add require 'api_struct' where used, because error the UnitializedConstant error is raised in some cases (in Rails app)

4. Edit the options arg for Uploadcare::Client::WebhookClient#update, so this method can be used with ruby 3.0.0

Checklist