# Retrieve a macro

You can fetch a single macro (saved reply) by its ID. The macro will only be returned if it is visible to the authenticated user based on its visibility settings.
**Visibility Rules**
A macro is returned based on its `visible_to` setting:
- `everyone`: Always visible to all team members
- `specific_teams`: Only visible if the authenticated user belongs to one of the teams specified in `visible_to_team_ids`

If a macro exists but is not visible to the authenticated user, a 404 error is returned.
**Placeholder Transformation**
The API transforms Intercom placeholders to a more standard XML-like format in the `body` field:
- From: `{{user.name | fallback: 'there'}}`
- To: `<attribute key="user.name" default="there"/>`

Default values in placeholders are HTML-escaped for security.

Endpoint: GET /macros/{id}
Version: Preview
Security: bearerAuth

## Path parameters:

  - `id` (string, required)
    The unique identifier of the macro

## Header parameters:

  - `Intercom-Version` (string)

## Response 200 fields (application/json):

  - `type` (string)
    String representing the object's type. Always has the value `macro`.
    Enum: "macro"

  - `id` (string)
    The unique identifier for the macro.
    Example: 123

  - `name` (string)
    The name of the macro.
    Example: Order Status Update

  - `body` (string)
    The body of the macro in HTML format with placeholders transformed to XML-like format.
    Example: <p>Hi <attribute key="user.name" default="there"/>, your order is ready!</p>

  - `body_text` (string)
    The plain text version of the macro body with original Intercom placeholder format.
    Example: Hi {{user.name|fallback:"there"}}, your order is ready!

  - `created_at` (string)
    The time the macro was created in ISO 8601 format.
    Example: 2025-07-17T11:18:08.000Z

  - `updated_at` (string)
    The time the macro was last updated in ISO 8601 format.
    Example: 2025-07-17T15:30:24.000Z

  - `visible_to` (string)
    Who can view this macro.
    Enum: "everyone", "specific_teams"

  - `visible_to_team_ids` (array)
    The team IDs that can view this macro when visible_to is set to specific_teams.
    Example: ["456","789"]

  - `available_on` (array)
    Where the macro is available for use.
    Example: ["inbox","messenger"]

## Response 401 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 403 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 404 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

