accounting_automation: опция gmailIncludeSpam (письма подрядчиков в спаме)
All checks were successful
ci / test (push) Successful in 39s
ci / deploy (push) Successful in 2m43s

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-23 16:41:33 +03:00
parent 4922d8f044
commit 115303ac07
3 changed files with 6 additions and 0 deletions

View File

@@ -65,6 +65,7 @@ const app = buildApi({
auth,
user: s.google.gmailUser,
query: s.google.gmailQuery,
includeSpam: s.google.gmailIncludeSpam,
processedIds: async (ids) => {
const { rows } = await pool.query("select message_id from acc_mail_processed where message_id = any($1) and result <> 'error'", [ids]);
return new Set(rows.map((r) => r.message_id as string));