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


## Overview

> Macro (excerpt)
> 
> Automatically update a Status macro when workflow state changes

A workflow can be configured to automatically update the Status macro caption to be the current workflow state name when a state transition occurs.

Note: This is primarily for older templates. Where possible, use the [Page Status Macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650152760) instead.

## Workflow setup

Use the `updatestatus=true` parameter on the [workflow macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649662219).

```plaintext
{workflow:name=Update status|updatestatus=true}
   {state:First}
   {state}
   {state:Second}
   {state}
{workflow}
```

## Adding the macro

To add the macro to a page:

1. In the editor, choose **Insert **> Macro (inline-media-image)

**→ Status**
2. Set the **Title**, **Color** and **Outline Style** to whatever you want
3. Choose **Insert**

Here's how the macro looks on your page:

[State]

Whenever the workflow state changes, the status macro will be updated to reflect the current workflow state.

> ✅ The current workflow state for an applied workflow state on a page is stored as a value reference - this can be retrieved as a metadata value using `@awpState@` using the [get-metadata](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649826804) macro or an appropriate reporting app or third party macro.

## See also

[User Guide](https://appfire.atlassian.net/wiki/spaces/CDML/pages/648907144):

- [Workflow Status Bar](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650117676)

[Reporting Guide](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649070833):

- [Report on states](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650216427)

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

- [States](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649595551)
- [pagestatus macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694558)