Retrieve a message's content
GET/v1/messages/{id}/content
Requires an API key with the messages:read scope. About keys and scopes
Works with integration, agent and partner keys.
Returns the subject, preview text, sender and body (or the push content) of a transactional send as it was accepted; merge tags appear unrendered. Kept for the workspace retention period, 30 days by default, and not kept once sent for a sensitive send: that, and expired content, return 404 CONTENT_NOT_RETAINED. So does a campaign or journey message, whose content is the campaign's or the journey version's: read it there.
Path parameters
idstringrequiredThe message's id.
uuid
Header parameters
Kirora-WorkspacestringoptionalPartner keys only: the child workspace to act in, by the external id the partner gave it. Without it, a partner key acts in its own workspace. Any other key that sends it is refused with 403, and an unknown workspace is 404.
pattern
^[A-Za-z0-9._:-]{1,128}$
Returns
Returns 200 OK with a MessageContent in data. Otherwise returns an error; Errors lists every code and which to retry.
channelstringrequiredone of
email,pushemailobject | nullrequired6 child attributes
subjectstringrequiredThe subject line. Merge tags are allowed.
1–998 characters
previewTextstringoptionalShown by inboxes after the subject. Merge tags are allowed; keep it near 100 characters.
1–255 characters
htmlstringrequiredThe HTML body. Rendered from the design when one is set.
1–512,000 characters
textstringoptionalThe plain-text alternative.
1–512,000 characters
fromstringrequiredThe sender address, on a verified sending domain.
1–320 characters
replyTostringoptionalWhere replies go; the part before the @ must be ASCII.
email
pushobject | nullrequired13 child attributes
titlestringrequiredThe notification title (up to 100 characters).
1–100 characters
bodystringrequiredThe notification text (up to 500 characters).
1–500 characters
actionUrlstringoptionalThe HTTPS page opened when the notification is tapped.
uri · up to 2,048 characters
imageUrlstringoptionalA large picture: web and Android show it; iOS needs the app's service extension.
uri · up to 2,048 characters
iconUrlstringoptionalWeb only; iOS and Android show the app's own notification icon.
uri · up to 2,048 characters
datamap<string, string>optionalUp to 10 string key-value pairs passed to the app untouched, for deep links and in-app routing.
at most 10 keys · keys: pattern
^[A-Za-z0-9_.-]{1,64}$· values: up to 1,024 charactersbuttonsobject[]optionalUp to 2 action buttons.
at least 1 item · at most 2 items
2 child attributes
titlestringrequiredThe button label.
1–30 characters
urlstringrequiredThe HTTPS page the button opens.
uri · up to 2,048 characters
collapseKeystringoptionalA newer notification with the same key replaces the older one on the device.
pattern
^[A-Za-z0-9_-]{1,64}$soundstringoptionalThe name of a sound the app ships; the device's default if unset.
1–64 characters
badgeintegeroptionalThe number shown on the iOS app icon.
min 0 · max 99999
ttlDurationOrZerooptionalHow long a provider keeps trying an offline device, up to 28 days; zero delivers now or never. Defaults to one day.
2 child attributes
valueintegerrequiredmin 0
unitstringrequiredone of
seconds,minutes,hours,days
urgencystringoptionalhighasks the push service to deliver promptly, even to a sleeping device;normallets it wait for a good moment to save battery. Device settings and the app still decide whether and how it is shown. Unset, a transactional push ishighand any othernormal.one of
high,normaloverridesobjectoptionalFields that differ on one platform, each replacing the shared one there (a whole
datamap, not merged key by key). On iOS and AndroidactionUrlmay be an app link such asmyapp://orders; the shared one and the web one must be HTTPS.3 child attributes
iosobjectoptionalReplaces shared fields on iOS.
14 child attributes
titlestringoptionalThe notification title (up to 100 characters).
1–100 characters
bodystringoptionalThe notification text (up to 500 characters).
1–500 characters
actionUrlstringoptionalpattern
^[a-z][a-z0-9+.-]*:\S+$· up to 2,048 charactersimageUrlstringoptionalA large picture: web and Android show it; iOS needs the app's service extension.
uri · up to 2,048 characters
iconUrlstringoptionalWeb only; iOS and Android show the app's own notification icon.
uri · up to 2,048 characters
datamap<string, string>optionalUp to 10 string key-value pairs passed to the app untouched, for deep links and in-app routing.
at most 10 keys · keys: pattern
^[A-Za-z0-9_.-]{1,64}$· values: up to 1,024 charactersbuttonsobject[]optionalUp to 2 action buttons.
at least 1 item · at most 2 items
2 child attributes
titlestringrequiredThe button label.
1–30 characters
urlstringrequiredThe HTTPS page the button opens.
uri · up to 2,048 characters
collapseKeystringoptionalA newer notification with the same key replaces the older one on the device.
pattern
^[A-Za-z0-9_-]{1,64}$soundstringoptionalThe name of a sound the app ships; the device's default if unset.
1–64 characters
badgeintegeroptionalThe number shown on the iOS app icon.
min 0 · max 99999
ttlDurationOrZerooptionalHow long a provider keeps trying an offline device, up to 28 days; zero delivers now or never. Defaults to one day.
2 child attributes
valueintegerrequiredmin 0
unitstringrequiredone of
seconds,minutes,hours,days
urgencystringoptionalhighasks the push service to deliver promptly, even to a sleeping device;normallets it wait for a good moment to save battery. Device settings and the app still decide whether and how it is shown. Unset, a transactional push ishighand any othernormal.one of
high,normalinterruptionLevelstringoptionalHow iOS presents it:
passivearrives silently,time-sensitivecan break through Focus when the user allows it, and needs the app's Time Sensitive Notifications capability.one of
passive,active,time-sensitivethreadIdstringoptionalNotifications with the same thread are grouped together in Notification Center.
pattern
^[A-Za-z0-9_.-]{1,64}$
androidobjectoptionalReplaces shared fields on Android.
13 child attributes
titlestringoptionalThe notification title (up to 100 characters).
1–100 characters
bodystringoptionalThe notification text (up to 500 characters).
1–500 characters
actionUrlstringoptionalpattern
^[a-z][a-z0-9+.-]*:\S+$· up to 2,048 charactersimageUrlstringoptionalA large picture: web and Android show it; iOS needs the app's service extension.
uri · up to 2,048 characters
iconUrlstringoptionalWeb only; iOS and Android show the app's own notification icon.
uri · up to 2,048 characters
datamap<string, string>optionalUp to 10 string key-value pairs passed to the app untouched, for deep links and in-app routing.
at most 10 keys · keys: pattern
^[A-Za-z0-9_.-]{1,64}$· values: up to 1,024 charactersbuttonsobject[]optionalUp to 2 action buttons.
at least 1 item · at most 2 items
2 child attributes
titlestringrequiredThe button label.
1–30 characters
urlstringrequiredThe HTTPS page the button opens.
uri · up to 2,048 characters
collapseKeystringoptionalA newer notification with the same key replaces the older one on the device.
pattern
^[A-Za-z0-9_-]{1,64}$soundstringoptionalThe name of a sound the app ships; the device's default if unset.
1–64 characters
badgeintegeroptionalThe number shown on the iOS app icon.
min 0 · max 99999
ttlDurationOrZerooptionalHow long a provider keeps trying an offline device, up to 28 days; zero delivers now or never. Defaults to one day.
2 child attributes
valueintegerrequiredmin 0
unitstringrequiredone of
seconds,minutes,hours,days
urgencystringoptionalhighasks the push service to deliver promptly, even to a sleeping device;normallets it wait for a good moment to save battery. Device settings and the app still decide whether and how it is shown. Unset, a transactional push ishighand any othernormal.one of
high,normalchannelIdstringoptionalThe Android notification channel to post in, which the app creates; it sets the sound and importance a person can tune, e.g. one for offers and one for orders.
pattern
^[A-Za-z0-9_.-]{1,64}$
webobjectoptionalReplaces shared fields on web.
12 child attributes
titlestringoptionalThe notification title (up to 100 characters).
1–100 characters
bodystringoptionalThe notification text (up to 500 characters).
1–500 characters
actionUrlstringoptionalThe HTTPS page opened when the notification is tapped.
uri · up to 2,048 characters
imageUrlstringoptionalA large picture: web and Android show it; iOS needs the app's service extension.
uri · up to 2,048 characters
iconUrlstringoptionalWeb only; iOS and Android show the app's own notification icon.
uri · up to 2,048 characters
datamap<string, string>optionalUp to 10 string key-value pairs passed to the app untouched, for deep links and in-app routing.
at most 10 keys · keys: pattern
^[A-Za-z0-9_.-]{1,64}$· values: up to 1,024 charactersbuttonsobject[]optionalUp to 2 action buttons.
at least 1 item · at most 2 items
2 child attributes
titlestringrequiredThe button label.
1–30 characters
urlstringrequiredThe HTTPS page the button opens.
uri · up to 2,048 characters
collapseKeystringoptionalA newer notification with the same key replaces the older one on the device.
pattern
^[A-Za-z0-9_-]{1,64}$soundstringoptionalThe name of a sound the app ships; the device's default if unset.
1–64 characters
badgeintegeroptionalThe number shown on the iOS app icon.
min 0 · max 99999
ttlDurationOrZerooptionalHow long a provider keeps trying an offline device, up to 28 days; zero delivers now or never. Defaults to one day.
2 child attributes
valueintegerrequiredmin 0
unitstringrequiredone of
seconds,minutes,hours,days
urgencystringoptionalhighasks the push service to deliver promptly, even to a sleeping device;normallets it wait for a good moment to save battery. Device settings and the app still decide whether and how it is shown. Unset, a transactional push ishighand any othernormal.one of
high,normal