I want to include files stored in confluence in my PlantUML code.
I can include files from github: as in
@startuml
!includeurl https://raw.githubusercontent.com/RicardoNiepel/C4-PlantUML/master/C4_Container.puml
Container_Boundary('ll','lll')
@enduml
I have files loaded as attachments to pages. How do I find the URL??
The attachments page lists them, if I select and right click I get
https://<space>/wiki/download/attachments/1402339539/<file>?api=v2
I just want to link to the file ....
Thanks
Hey David,
I think you've found how to get the address of the attachment already! Just as you noted, from the Attachments page you just right-click the attachment you want to link and copy the hyperlink.
You can strip the "?api=v2" from the end of the URL if the system you're trying to use expects to see .jpg or .png at the end of a URL. It's not required to display the file.
What you might be running into is a permissions problem. Confluence will protect your attachments from unauthorized users if the space/page are not set for anonymous access. PlantUML or another service trying to load that URL from an unauthenticated source might be hitting the login screen (and throwing an error because the login screen isn't an attachment). If you want to set the entire space as public, you can read about how to do that here. Setting the space (and subsequently, the individual page you're on) to public will allow any user/system to access the content without having to sign in.
Hope that helps explain things!
Daniel
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.