dependencies: owocr: github: whats-this/owocr branch: master # as of now this requires 0.24.2 at the very least
First a client is needed:
require "owocr" client = OwO::WhatsThis.new "token", "optional user-agent for the requests", "optional api url"
You will then need to utilise one of the methods as listed:
OwO::WhatsThis#shorten(url : String|URI) : String- Shortens the given URL or URI and returns the shortened ID.
OwO::WhatsThis#upload(first : UploadData, second : UploadData?, third : UploadData? = nil) : Tuple(UploadedFileData?, UploadedFileData?, UploadedFileData?)- Uploads the file(s) and returns the uploaded file(s).
For more in-depth explanation of these, you can go to the OwO.codes API page.