louislam/uptime-kuma · error · Error
No recipient or group specified
Error message
No recipient or group specified
What it means
360messenger.js:118-120. After normalizing both recipient phone numbers and group IDs (supporting comma/semicolon lists and arrays), if BOTH lists are empty the send has no destination, so it throws rather than making a pointless API call.
Source
Thrown at server/notification-providers/360messenger.js:119
})
);
return `${okMsg} (Sent to ${groupIds.length} group(s))`;
} else if (hasRecipient) {
// Send to recipient(s) only
await Promise.all(
recipients.map((recipient) => {
const data = {
phonenumber: recipient,
text: message,
};
return axios.post("https://api.360messenger.com/v2/sendMessage", data, config);
})
);
return `${okMsg} (Sent to ${recipients.length} recipient(s))`;
} else {
throw new Error("No recipient or group specified");
}
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
/**
* Apply template with variables
* @param {string} template - Template string
* @param {string} msg - Default message
* @param {object} monitorJSON - Monitor data
* @param {object} heartbeatJSON - Heartbeat data
* @returns {string} Formatted message
*/
applyTemplate(template, msg, monitorJSON, heartbeatJSON) {
try {
// Simple template replacement
let result = template;View on GitHub (pinned to 6b5ea01557)
Solutions
- Open the notification settings and set at least one recipient phone number or group id.
- Strip stray separators: ensure the field contains actual values, not just ',' or ';'.
- If using group IDs, verify Whatsapp360messengerGroupIds is an array or a delimited string with real entries.
- Add front-end/DB validation so the provider cannot be saved without a destination.
Defensive patterns
Strategy: validation
Validate before calling
// Validate that at least one destination exists before calling send
function hasDestination(notification) {
const recipient = (notification.Whatsapp360messengerRecipient || '').split(/[;,]/).map(s=>s.trim()).filter(Boolean);
const groups = [].concat(notification.Whatsapp360messengerGroupIds || notification.Whatsapp360messengerGroupId || [])
.map(g => typeof g === 'object' ? g?.id : g).map(String).map(s=>s.trim()).filter(Boolean);
return recipient.length + groups.length > 0;
}
if (!hasDestination(notification)) throw new Error('No recipient or group specified'); Type guard
function isNonEmptyDestinationList(notification) {
return Boolean(notification) && (
(notification.Whatsapp360messengerRecipient || '').trim() !== '' ||
Boolean(notification.Whatsapp360messengerGroupIds?.length) ||
Boolean(notification.Whatsapp360messengerGroupId)
);
} Try / catch
try { await provider.send(notification, msg, monitorJSON, heartbeatJSON); }
catch (e) {
if (e.message === 'No recipient or group specified') {
// config error — disable the provider or alert the user, do not retry blindly
throwGeneralAxiosError(e);
}
} Prevention
- Validate destinations on save in the UI, not at send time.
- After schema migrations, run a consistency check that all notification rows have non-empty destinations.
When it happens
Trigger: Notification saved with blank Whatsapp360messengerRecipient AND no Whatsapp360messengerGroupIds/GroupId; field was populated only with whitespace or a lone separator (';' or ','); a migration/import left the columns null.
Common situations: User configured the provider but never filled in a destination; recipient field renamed in a schema migration and the old value was not carried over; front-end validation allowed an empty submit.
Related errors
- No valid OpenWA chat ID found.
- Interval cannot be less than ${MIN_INTERVAL_SECOND} seconds
- Retry interval cannot be less than ${MIN_INTERVAL_SECOND} se
- Response max length cannot be less than 0
- Response max length cannot be more than ${RESPONSE_BODY_LENG
AI-assisted analysis of louislam/uptime-kuma@6b5ea01557 (2026-08-12).
Data as JSON: /api/errors/eacfa7d1a370f0d9.
Report an issue: GitHub.