44:    account_ids: list = []
80:        "account_ids": c.account_ids or [],
105:        raise HTTPException(status_code=404, detail="Campaign not found")
128:            errors.append("Recipient list not found")
141:            errors.append(f"Subject line {sid} not found")
148:            errors.append(f"Template {tid} not found")
152:    if not data.account_ids:
154:    elif len(data.account_ids) > cfg.MAX_GMAIL_ACCOUNTS_PER_CAMPAIGN:
157:        for aid in data.account_ids:
160:                errors.append(f"Gmail account {aid} not found")
193:    q = select(Campaign).where(Campaign.user_id == user.id)
267:    rows = (await db.execute(select(Campaign).where(Campaign.user_id == user.id))).scalars().all()
303:        raise HTTPException(status_code=400, detail="Recipient list not found")
385:            raise HTTPException(status_code=400, detail="Recipient list not found")
638:    lists = (await db.execute(select(RecipientList).where(RecipientList.user_id == user.id)
640:    subjects = (await db.execute(select(SubjectLine).where(SubjectLine.user_id == user.id)
642:    templates = (await db.execute(select(EmailTemplate).where(EmailTemplate.user_id == user.id)
644:    accounts = (await db.execute(select(GmailAccount).where(GmailAccount.user_id == user.id,
647:    phones = (await db.execute(select(CompanyPhoneNumber).where(CompanyPhoneNumber.user_id == user.id,
649:    attachments = (await db.execute(select(Attachment).where(Attachment.user_id == user.id)
727:        if not data.get("account_ids"):
729:        elif len(data["account_ids"]) > cfg.MAX_GMAIL_ACCOUNTS_PER_CAMPAIGN:
