Programmatically compressing/optimizing a PDF on a Windows machine using .Net, python or cmd
Copy link to clipboard
Copied
The following page stongly suggests that there are three ways to do this: https://opensource.adobe.com/dc-acrobat-sdk-docs/. See "Compress documents" in the Feature Comparision table. It looks like you can do it via DC, PDFL or Acrobat SDKs. I have Acrobat Standard installed on this computer. .Net is my preferred route, but I can use Python or execute a command line program from either of those. Is this possible?
If a .Net approach is available, what references do I have to add to my project (which specific assemblies/DLLs)? Ideally someone could provide a *complete* code example. I don't necessarily need to fine tune the compression. I just need functionality very similar to manual "Optimize PDF" in Acrobat Standard.
I would like to stay within the Adobe 'ecosystem' and not rely on some third part that may come with issues or unnacceptable (low quality/resolution) output files.
Thanks!
Copy link to clipboard
Copied
Hi,
I know this is not keeping inside the Acrobat Standard eco-system but it is staying inside the above eco system you could use this API -
https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/compress-pdf/
Copy link to clipboard
Copied
Thanks! I was looking for a free option but I think we may stay in the Free Tier since we probably won't exceed 500 documents per month . It sounds like compressing PDFs would be included in the "all 15+ PDF Services" part. Can anyone confirm?
Copy link to clipboard
Copied
Hi,
yes it is

