Might Shortcuts be able to do it? I know there’s a Convert Image action, but I’m not sure if it will take a PDF as input.