Skip to content

In-app messages (management API)

View as Markdown

Messages the SDK shows inside your app. A new message starts off. Any endpoint that takes {message} accepts its ID or its name. For what each setting does, see the user guide.

Every path also works under /v1/manage/appspaces/{appspace}, which you need when an OAuth token reaches more than one Appspace. See the management API overview for signing in, errors, dry runs and paging.

MethodPathWhat it doesPermission
GET/v1/manage/messagesList in-app messagesRead
POST/v1/manage/messagesCreate an in-app messageRead and write
GET/v1/manage/messages/{message}Get an in-app messageRead
PATCH/v1/manage/messages/{message}Change an in-app messageRead and write
DELETE/v1/manage/messages/{message}Delete an in-app messageRead and write
GET/v1/manage/messages/{message}/previewPreview an in-app messageRead
PUT/v1/manage/messages/{message}/contentPublish a message’s designRead and write
POST/v1/manage/messages/{message}/activateTurn an in-app message onRead and write
POST/v1/manage/messages/{message}/deactivateTurn an in-app message offRead and write
POST/v1/manage/messages/{message}/restoreRestore a deleted in-app messageRead and write
GET/v1/manage/messages

Permission: Read.

The Appspace’s in-app messages, highest priority first, paged with cursor: each with every field a change takes (the design itself only from GET /messages/{message}), and whether it shows now.

Query parameters:

ParameterTypeRequiredDescription
triggermanual, milestone, eventNoOnly messages with this trigger.
activetrue, falseNoOnly messages that are on (true) or off (false).
limitintegerNoHow many to return, 1 to 100 (default 50).
cursorstringNoFrom the previous page’s next_cursor, to get the page after it.

Response 200: a page of results in data, and next_cursor for the next page (see Paging). Each item:

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
POST/v1/manage/messages

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

The dashboard’s rules apply: a name, Free’s one message (403 plan_limit) and manual trigger, and an audience of this Appspace. A new message is off unless active is true; add the design with PUT /messages/{message}/content, preview it, then activate it. Send Idempotency-Key so a retry never makes two. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Request body (JSON):

FieldTypeRequiredDescription
namestringYesA name for your team, such as “Spring sale”. Not shown to people.
titlestringNoThe headline people see. Default: the name.
bodystring or nullNoThe text under the title, for a message without a design (and the fallback for one).
triggermanual, milestone, eventNoWhen the app shows it. manual (default): when your code asks (Tolinku.messages / showMessage). milestone: when someone reaches a referral step (trigger_value, such as installed). event: when your app asks for messages for an event by name (trigger_value). Free: manual only.
trigger_valuestring or nullNoThe milestone or event name, for those triggers.
background_colorstring or nullNoThe card’s colour, #RRGGBB (default #ffffff). A design’s own background wins.
priorityintegerNoWhen several messages qualify at once, only the highest shows. Default 0.
dismiss_daysinteger or nullNoAfter someone closes it, hide it from them for this many days. Empty: a close isn’t remembered.
max_impressionsinteger or nullNoShow it at most this many times to each person (1: a one-time announcement). Empty: no limit. Not on Free.
min_interval_hoursinteger or nullNoAt least this many hours between two showings. Empty: no gap. Not on Free.
starts_atstring or nullNoWhen it starts showing. ISO 8601, such as 2026-12-01T09:00:00Z. Empty: none.
ends_atstring or nullNoWhen it stops showing. ISO 8601, such as 2026-12-01T09:00:00Z. Empty: none.
audience_idstring or nullNoOnly show it to people in this audience: its id or its name (an audience of this Appspace). The app must identify the user (setUserId). Empty: everyone. Not on Free.
ab_eligiblebooleanNoWhether A/B tests may use this message. Default false.
activebooleanNoWhether it shows straight away. Default false, as in the dashboard: add the content, preview it, then turn it on.

Response 201: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
GET/v1/manage/messages/{message}

Permission: Read.

One message: every field a change takes, by the same names, its published design (content) and whether it shows now.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Response 200: the result in data, with preview.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
PATCH/v1/manage/messages/{message}

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Its settings: only the fields sent change; null clears one. The design is PUT /messages/{message}/content. Send expected_updated_at and a change made in the meantime is refused with 412. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Request body (JSON):

FieldTypeRequiredDescription
namestringNoA new name.
titlestringNoA new headline.
bodystring or nullNoThe text under the title, for a message without a design (and the fallback for one).
triggermanual, milestone, eventNoWhen the app shows it. manual (default): when your code asks (Tolinku.messages / showMessage). milestone: when someone reaches a referral step (trigger_value, such as installed). event: when your app asks for messages for an event by name (trigger_value). Free: manual only.
trigger_valuestring or nullNoThe milestone or event name, for those triggers.
background_colorstring or nullNoThe card’s colour, #RRGGBB (default #ffffff). A design’s own background wins.
priorityintegerNoWhen several messages qualify at once, only the highest shows. Default 0.
dismiss_daysinteger or nullNoAfter someone closes it, hide it from them for this many days. Empty: a close isn’t remembered.
max_impressionsinteger or nullNoShow it at most this many times to each person (1: a one-time announcement). Empty: no limit. Not on Free.
min_interval_hoursinteger or nullNoAt least this many hours between two showings. Empty: no gap. Not on Free.
starts_atstring or nullNoWhen it starts showing. ISO 8601, such as 2026-12-01T09:00:00Z. Empty: none.
ends_atstring or nullNoWhen it stops showing. ISO 8601, such as 2026-12-01T09:00:00Z. Empty: none.
audience_idstring or nullNoOnly show it to people in this audience: its id or its name (an audience of this Appspace). The app must identify the user (setUserId). Empty: everyone. Not on Free.
ab_eligiblebooleanNoWhether A/B tests may use this message. Default false.
expected_updated_atstringNoThe updated_at you read. If the thing has changed since, nothing is saved and the answer is 412 precondition_failed: read it again and retry.

Response 200: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
DELETE/v1/manage/messages/{message}

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Apps stop showing it at once. It goes to the trash with its design and draft, and can be restored for 30 days. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Response 200: the result in data, with warnings. With dry_run, a preview instead.

FieldTypeDescription
deletedtrue
idstring
namestring
trash_idstringThe trash entry: POST /trash/{id}/restore, or POST /messages/{message}/restore, brings it back.
restorable_untilstring
GET/v1/manage/messages/{message}/preview

Permission: Read.

The HTML the apps show for it (the renderer behind /v1/api/messages/{id}/render, without its reporting), with a summary in words. Send Accept: text/html for the page itself. There is no PNG.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Response 200: the result in data.

FieldTypeDescription
htmlstringA whole HTML document; open it in a browser or a phone-sized frame.
summarystring
showing_nowboolean
pngnullNo screenshot: the HTML is the preview.
PUT/v1/manage/messages/{message}/content

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Replaces the published design, checked exactly as the visual builder’s publish is (a content array of components with a type and object props, within 1 MB, 20 levels and 500 components). Text is always shown as text; links and images that could run code are left out by the apps, and the answer warns about them and about components the apps don’t draw. The copy joins the publish history; a person’s unpublished draft in the builder is left alone. Not on Free. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Request body (JSON):

FieldTypeRequiredDescription
contentobject or stringYesThe design, as the visual builder saves it (Puck data): { “root”: { “props”: { “bgColor”: “#ffffff”, “padding”: 24 } }, “content”: [ { “type”: “Heading”, “props”: { “id”: “h1”, “text”: “Hi”, “fontSize”: 24 } }, { “type”: “TextBlock”, “props”: { “id”: “t1”, “content”: “Text, with links” } }, { “type”: “Button”, “props”: { “id”: “b1”, “label”: “Shop now”, “action”: “https://example.com/sale” } } ], “zones”: {} }. Components: Heading, TextBlock, Image (url, alt, width), Button (label, action: a URL or “close”; style filled, outline or soft; bgColor, textColor), Section (bgColor, padding; its children in zones[“<id>:content”]), Spacer (height), Divider, AppIcon, StoreButtons, DeepLinkButton. Text is shown as text, never HTML. At most 1 MB. Also a JSON string of the same.
expected_updated_atstringNoThe updated_at you read. If the thing has changed since, nothing is saved and the answer is 412 precondition_failed: read it again and retry.

Response 200: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
POST/v1/manage/messages/{message}/activate

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Apps show it from their next check, within its schedule and trigger. Already on: nothing changes. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Response 200: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
POST/v1/manage/messages/{message}/deactivate

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Apps stop showing it from their next check; nothing else changes. Already off: nothing changes. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe message: its id or its name. URL-encode a name.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Response 200: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
POST/v1/manage/messages/{message}/restore

Permission: Read and write. Changes something: takes dry_run and Idempotency-Key, and needs the Standard plan or above.

Brings back a message deleted in the last 30 days, with the same id, design and history, on or off as it was. {message} is its old id or name, or the trash entry’s id. On Free, refused with 409 conflict while there’s another message. With dry_run, nothing changes: the answer is { dry_run: true, before, after, changes, warnings }.

Path parameters:

ParameterDescription
messageThe deleted message: its old id or name, or the trash entry’s id.

Query parameters:

ParameterTypeRequiredDescription
dry_runtrue, falseNotrue: check and preview the change without making it (the same as dry_run in the body).

Response 200: the result in data, with preview and warnings. With dry_run, a preview instead.

FieldTypeDescription
idstringThe message’s id. Any endpoint taking {message} also takes its name.
namestring
titlestring
bodystring or null
triggermanual, milestone, event
trigger_valuestring or null
background_colorstring
prioritynumber
dismiss_daysnumber or null
max_impressionsnumber or null
min_interval_hoursnumber or null
starts_atstring or null
ends_atstring or null
audience_idstring or null
audience_namestring or null
ab_eligibleboolean
activebooleanOn or off (POST /activate, /deactivate).
showing_nowbooleanOn, and within its schedule (the app still decides when, by the trigger).
statestring
has_contentbooleanWhether it has a design (content); without one, apps show the title and body.
draftobject or nullUnpublished changes someone has in the visual builder, if any.
draft.updated_atstring or null
draft.bystring or null
createdstring
updated_atstringSend as expected_updated_at when changing it, so a change made since isn’t overwritten.
contentobject or nullThe published design (Puck data), as PUT /messages/{message}/content takes it; null without one.
Was this page helpful?