---
title: "get-metadata macro"
canonical: "https://support.appfire.com/space/CDML/649826804/get-metadata%20macro"
format: markdown
---
> Macro (aura-html)


## Overview

> Macro (excerpt)
> 
> Retrieve and display [Value References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694302)

The `get-metadata` macro is used on wiki pages (or content rendered to wiki pages) to retrieve and display [Value References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694302), including:

- [Attribute References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728358)
- [Metadata references](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649925583)
- [Page Property References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728272)
- [Parameter References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649760641)
- [Supplier References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649532510)
- [Page and User references](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649827717)

## Where to use it?

Optional.

One or more `get-metadata` macros can be used in wiki content (pages, blog posts).

It can also be used in macros that render wiki content in the context of pages and blog posts.

> Macro (contentbylabel)

It can also be used in [page templates](https://confluence.atlassian.com/doc/page-templates-296093785.html) and [blueprints](https://confluence.atlassian.com/doc/blueprints-323982376.html).

## Parameters

| **Parameter** | **Required** | **Default** | **Notes** | **Ver** |
| --- | --- | --- | --- | --- |
| `name` | :check_mark: |  | The metadata or value reference to display<br>- [Workflow Parameter Name](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649760641)
- [Value Name](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694302)
- [Supplier Reference](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649532510)
- etc<br>> ℹ️ - **do not enclose** the value reference in `@` ("at") symbols
> ℹ️ - use `awpState` value reference to retrieve the current workflow state name | 3.0.3+ |

## Example

To retrieve a value reference called `@Project Lead@`, add the `get-metadata` macro to content using the macro editor to add the metadata name.

![image](media://8f62ecf7-e74d-4ee3-ad5c-153d39b4c35b)

> 📝 Do not include the `@` symbols when adding the value reference name to the macro editor.

<span style="color: #172b4d">A simple way to display the value is to add the macro to a table cell.</span>

![image](media://d66453cb-df00-4a5b-a0e9-ab11bf098708)

<span style="color: #172b4d">On the content, this retrieves and displays the current value of the metadata.</span>

![image](media://4d6f1061-4bae-4841-bbc1-e77f64ff259e)

<span style="color: #172b4d">In the markup notation:</span>

```plaintext
{get-metadata:name=Project Lead}
```

> 📝 <span style="color: #172b4d">Metadata values created with the </span><span style="color: #172b4d">[set-metadata macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650251172)</span><span style="color: #172b4d"> are only indexed by Confluence and appear in the Confluence search if the </span><span style="color: #172b4d">[Comala Metadata app](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649956848)</span><span style="color: #172b4d"> is installed.</span>

## Metadata retrieval logic

The following may cause problems when trying to retrieve a metadata value using the `get-metadata` macro.

For example

- in Comala Document Management versions prior to v6.18.8 using a `get-metadata` macro to define a page property value where the metadata being retrieved is the value of another `get-metadata` macro

The retrieval logic of the `get-metadata` macro may also have problems returning a value if there is any coincidence (or overlap) in a metadata name and another metadata or property name. To avoid any problem simply try to ensure the use of unique names for each of your metadata names.

Suppose duplication of a [value reference](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694302) name occurs, for example, a page property and metadata set with the Comala [set-metadata](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650251172) macro.

In that case, the `get-metadata` macro resolves the value in the following priority

> Macro (excerpt-include)



## All examples

> Macro (contentbylabel)

## See also

[Workflow Authoring Guide](https://appfire.atlassian.net/wiki/spaces/CDML/pages/648611901)

- [Value References](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694302)
- [Conditions](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694110)
- [Events](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649759655)
- [Triggers](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649563178)
- [Actions](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649858941)

[Integration Guides](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649396230)

- [Comala Metadata app](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649956848)
- [Communardo Metadata for Confluence app](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650348379)
- [Appfire Scaffolding Forms and Templates app](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650315581)