Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Can I link to a PDF by page name?

Greg MacLellan February 3, 2014

While viewing a page, such as /display/DOC/Page+Name, you can click "Export to PDF" and get a url like /spaces/flyingpdf/pdfpageexport.action?pageId=403746. Is it possible to get the PDF URL using the space and page name?

What I'd like to do is have my CI build automatically fetch release notes as a PDF, which are named based on the version number. It would be very easy if it just has to grab a URL (such as /display/DOC/Page+Name?format=pdf or /display-pdf/DOC/Page+Name), since the CI server knows the version number, but doesn't know the confluence pageId.

2 answers

0 votes
Steve Gerstner [bridgingIT]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 4, 2014

Hi Greg,

if you can develop a plugin, you can write a plugin with a servlet module to do so. The Servlet can get the id via the api and make a redirect to the pdf url, which uses the pageid as a parameter.

Regards

Steve

0 votes
Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 3, 2014

It is not possible to do by page name. Could you go to SQL in your build to look up the id and then submit the URL?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events