Key value pairs supported in confluence articles?

Michael Jeszenka
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 30, 2020

Hello,

I'm wondering if it is possible in confluence to define key-value pairs that I can reference in my articles. For example, if I have a url that I will include in my documentation on several difference articles, I would like to define that url once as a key value pair and simply reference that key in each of my articles, instead of entering the url. This way if the url ever changes, I can edit it in my key value pair and have it reflected on every article that it was referenced from.

Is something like this possible?

1 answer

1 accepted

0 votes
Answer accepted
Daniel Eads
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 30, 2020

Hello Michael, welcome to the Community!

This is an interesting use-case. I understand you're hoping to define an item once (in this case, a URL) and re-use it multiple times across Confluence. I can think of a few various ways that similar things can be done:

  1. The exerpt macro may be the most straightforward way - on a page, you add the excerpt macro and put the text you want to reuse inside it. On separate pages (your articles in this case), you use the excerpt include macro to bring in the excerpt from the first page. A single edit on the first page updates the text in all the subsequent pages you used the excerpt include macro on.
  2. It's possible to use a Glossary app for something like this (a little more in-line than an excerpt). The term would be the key part of the keypair, and the definition would be the URL you want to link to. Updating the glossary definition would be the way to update the URL. Check out the Glossary apps available for Confluence Cloud here .
  3. URL shortening services are also a great way to solve this. You can create a shortened URL, and update the "actual" link endpoint at the shortening service if it changes in the future. This article outlines some URL shorteners that might be the cleanest-looking options.

Cheers,
Daniel

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events