My goal is to download all attachments of a given Case. I was managed to perform the needed queries to and I have a pointer to the ContentVersion object I need.
They problem is that I don't know how to download the attachment. I believe I need the VersionData field, which holds the file in binary format.
Another limitation that I have is that I'm using a Linux environment by means of its CLI prompt. I already made an authentication to SF by using SFDX API provided by SalesForce, but I cannot find a way to combine SFDX API with REST API's GET command to fetch the needed file so it will be downloaded to my Linux machine.