Upload a PDF and rename it before uploading it to a container volume

I want to use a file uploader to upload a PDF file.

Before the file is uploaded it needs to be a renamed to a certain format before upload. The data is then saved into MySQL and the local container volume. I am using Go File API to run this operation.

Once the file is uploaded I want to retrieve the file for the customer to download locally when required.

This is all happening on a self-hosted Retool that is on-premise.

How can this be achieved?