I'm kinda stuck in the middle of all the limitations Salesforce has for creating a pdf out of a Visualforce page.
What I have is a Visualforce page that takes some parameters and I use to rerender as a pdf using the getContent method inside an apex call.
The limitations I have:
- GetContent() can not be used inside: future method, trigger, cron job
- REST API: will cause a call out loop with the new critical update.
- Can not use restAPI inside cron jobs, or future methods, because I can not have a valid user session.
So my what I tried to do is to generate the pdf from a cron job and email it to a certain contact. Because of all the above limitations I'm kinda stuck.
Can you think of any other solution to solve this problem?