You must have Brew installed.
Use brew to install ghostscript.
The following command will convert all PDFs in the current and subdirectories to PDF 1.2 with a "2" at the end of the file. You can then delete all .pdf files and rename all .pdf2 files to .pdf, or move them, whatever you may want...
You can compile this script into an application to make a droplet.
Automator and Shortcut scripts don't resize images as expected. Here is an applescript that uses the command line image tool sips that comes with macOS/Mac OS X to do exactly as it's told, preserving aspect ratio.
If you are...