chore: show dm policy + allowlist preview

This commit is contained in:
Peter Steinberger
2026-01-08 11:25:17 +01:00
parent 8803787e48
commit 390b102563
2 changed files with 43 additions and 2 deletions

View File

@@ -63,6 +63,16 @@ export async function buildProviderSummary(
const details: string[] = [];
if (!account.enabled) details.push("disabled");
if (account.selfChatMode) details.push("self-chat");
const dmPolicy =
account.dmPolicy ?? effective.whatsapp?.dmPolicy ?? "pairing";
details.push(`dm:${dmPolicy}`);
const allowFrom = (account.allowFrom ?? effective.whatsapp?.allowFrom ?? [])
.map(normalizeE164)
.filter(Boolean)
.slice(0, 2);
if (allowFrom.length > 0) {
details.push(`allow:${allowFrom.join(",")}`);
}
lines.push(
accountLine(
formatAccountLabel({