You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Clarify macro visibility rules and team-based access control
- Add detailed explanation of when macros are accessible vs return 404
- Expand examples to show team-restricted and complex placeholder scenarios
- Document HTML escaping behavior for placeholder default values
- Improve parameter description for clarity
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <[email protected]>
Copy file name to clipboardExpand all lines: descriptions/0/api.intercom.io.yaml
+54-20Lines changed: 54 additions & 20 deletions
Original file line number
Diff line number
Diff line change
@@ -9338,55 +9338,75 @@ paths:
9338
9338
- name: id
9339
9339
in: path
9340
9340
required: true
9341
-
description: The ID of the macro to retrieve
9341
+
description: The unique identifier of the macro
9342
9342
schema:
9343
9343
type: string
9344
9344
example: "123"
9345
9345
tags:
9346
9346
- Macros
9347
9347
operationId: getMacro
9348
9348
description: |
9349
-
You can fetch a single macro by its ID.
9349
+
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.
9350
+
9351
+
**Visibility Rules**
9352
+
9353
+
A macro is returned based on its `visible_to` setting:
9354
+
- `everyone`: Always visible to all team members
9355
+
- `specific_teams`: Only visible if the authenticated user belongs to one of the teams specified in `visible_to_team_ids`
9356
+
9357
+
If a macro exists but is not visible to the authenticated user, a 404 error is returned.
9350
9358
9351
9359
**Placeholder Transformation**
9352
9360
9353
-
The API transforms Intercom placeholders to a more standard XML-like format:
9361
+
The API transforms Intercom placeholders to a more standard XML-like format in the `body` field:
9354
9362
- From: `{{user.name | fallback: 'there'}}`
9355
9363
- To: `<attribute key="user.name" default="there"/>`
9364
+
9365
+
Default values in placeholders are HTML-escaped for security.
9356
9366
responses:
9357
9367
'200':
9358
9368
description: Macro found
9359
9369
content:
9360
9370
application/json:
9361
9371
examples:
9362
-
Macro found:
9372
+
Macro visible to everyone:
9363
9373
value:
9364
9374
type: macro
9365
9375
id: "123"
9366
9376
name: "Order Status Update"
9367
-
body: "<p>Hi <attribute key=\"user.name\" default=\"there\"/>, your order #<attribute key=\"order.number\"/> is ready!</p>"
9368
-
body_text: "Hi there, your order is ready!"
9377
+
body: "<p>Hi <attribute key=\"user.name\" default=\"there\"/>, your order #<attribute key=\"order.number\"/> is ready for pickup!</p>"
9378
+
body_text: "Hi there, your order is ready for pickup!"
9369
9379
created_at: 1719474966
9370
9380
updated_at: 1719493757
9371
9381
visible_to: "everyone"
9372
9382
visible_to_team_ids: []
9373
9383
available_on: ["inbox", "messenger"]
9374
-
schema:
9375
-
"$ref": "#/components/schemas/macro"
9376
-
'404':
9377
-
description: Macro not found
9378
-
content:
9379
-
application/json:
9380
-
examples:
9381
-
Macro not found:
9384
+
Macro with team restrictions:
9382
9385
value:
9383
-
type: error.list
9384
-
request_id: bc300b1a-492a-405f-924e-a5881cb72e3a
9385
-
errors:
9386
-
- code: not_found
9387
-
message: Macro not found
9386
+
type: macro
9387
+
id: "456"
9388
+
name: "VIP Customer Support"
9389
+
body: "<p>Dear <attribute key=\"user.name\" default=\"valued customer\"/>, we appreciate your VIP status. Your dedicated support team is here to help.</p>"
9390
+
body_text: "Dear valued customer, we appreciate your VIP status. Your dedicated support team is here to help."
0 commit comments