FoyerDevelopers

Generated · Live registry

messaging_rules tools

7 tools in this domain, generated from the running registry.

All tool domains

messaging_rules.cancel_queue_item

writesconfirm

Cancel a PENDING scheduled guest message so it is never sent. Fails if it is no longer pending. Requires confirmation.

Input parameters

FieldTypeRequiredNotes
idstringyes
reasonstringno

Output fields

FieldTypeRequiredNotes
idstringyes
statusstringyes

messaging_rules.edit_queue_item

writesconfirm

Edit a PENDING scheduled guest message before it is sent — override its subject, body, and/or scheduled time. Fails if the message is no longer pending. Requires confirmation.

Input parameters

FieldTypeRequiredNotes
idstringyes
renderedSubjectstringno
renderedBodystringno
scheduledForstringno

Output fields

FieldTypeRequiredNotes
idstringyes
statusstringyes

messaging_rules.list_queue

read-only

List scheduled + already-sent automatic guest messages across all stays (the queue), newest first, optionally filtered by status (pending|sent|skipped|failed|cancelled). Each item carries the rule name, stay + room, scheduled time, channel, rendered subject, and outcome. Read-only.

Input parameters

FieldTypeRequiredNotes
statusenumnoOne of: pending, sent, skipped, failed, cancelled
limitintegerno

Output fields

FieldTypeRequiredNotes
itemsarray of objectyes
items.idstringyes
items.ruleNamestring · nullableyes
items.stayIdstringyes
items.stayRoomstring · nullableyes
items.scheduledForstringyes
items.statusstringyes
items.channelstring · nullableyes
items.renderedSubjectstring · nullableyes
items.sentAtstring · nullableyes
items.failureReasonstring · nullableyes

messaging_rules.list_rules

read-only

List the tenant's automatic guest-message rules: name, whether enabled, priority, the trigger (reference event + offset in minutes), and the channel. Read-only.

Input parameters

Returns object.

Output fields

FieldTypeRequiredNotes
itemsarray of objectyes
items.idstringyes
items.namestringyes
items.descriptionstring · nullableyes
items.enabledbooleanyes
items.prioritynumberyes
items.triggerReferencestringyes
items.triggerOffsetMinutesnumberyes
items.channelstringyes

messaging_rules.resend_queue_item

writesconfirm

Re-send an already-processed scheduled guest message (sent|failed|cancelled): clones it to a fresh PENDING row (new instance key, scheduled now) which the sender re-renders from the current rule + stay and dispatches. Bypasses idempotency; the original history row is kept. Requires confirmation.

Input parameters

FieldTypeRequiredNotes
idstringyes

Output fields

FieldTypeRequiredNotes
idstringyes
statusstringyes

messaging_rules.scheduled_for_stay

read-only

List the automatic guest messages scheduled for (and already sent to) one stay, ordered chronologically. Read-only. Each item carries the rule name, channel, scheduled time, status (pending|sent|skipped|failed|cancelled), rendered subject/body, and — when applicable — sent time and failure reason.

Input parameters

FieldTypeRequiredNotes
stayIdstringyes

Output fields

FieldTypeRequiredNotes
itemsarray of objectyes
items.idstringyes
items.ruleNamestring · nullableyes
items.scheduledForstringyes
items.statusstringyes
items.channelstring · nullableyes
items.renderedSubjectstring · nullableyes
items.renderedBodystring · nullableyes
items.sentAtstring · nullableyes
items.failureReasonstring · nullableyes

messaging_rules.seed_pre_arrival_defaults

writes

Idempotent seed: creates the 'Pre-Arrival Portal' messaging rule for the current tenant if no rule with triggerReference=check_in and a negative offset exists yet. The rule sends guests a portal link by email 48 hours before arrival (−2880 min offset) with German and English templates containing the %checkin_url% placeholder. Returns { seeded: true } when created, { seeded: false, reason: 'already_exists' } when skipped.

Input parameters

Returns object.

Output fields

FieldTypeRequiredNotes
seededbooleanyes
reasonstringnoOnly present when seeded=false.