Back to Portfolio

AI agent for B2B LinkedIn without a 'cloud bot'

How we built an AI agent for B2B LinkedIn: lead scoring, outreach drafts, CRM pipeline, and a local Chrome CDP bridge — approve-first by default, auto-send only behind limits.

The Challenge

The team already had a working direct sales channel on LinkedIn, but it scaled poorly: lead search and qualification, first-touch personalization, follow-up, and pipeline tracking consumed one seller's time. Mass bots and 'cloud sessions' were ruled out immediately — account risk and communication tone are more important than raw acceptance rate. We needed a product that speeds up touch preparation and runs CRM up to the meeting, while leaving control with a human at the start. Offer and market are configured in the system (voice, ICP, campaigns); the pilot model — founders and CEOs, custom software, Russian as the communication language.

Our Solution

Why the usual approach breaks

Approach Where it breaks
Manual outreach in spreadsheets Doesn't scale: research, drafts, and follow-up live in different places
Generic cloud bot LinkedIn session goes 'into someone else's browser'; weak control of tone and limits
'Just ChatGPT in a chat' No pipeline, audit, approve queue, or hard deny rules in code
Auto-send from day one Damages the account and brand faster than it produces pipeline

The client's requirement sounded engineering-simple: brains and database in the service; hands in LinkedIn on the seller's machine.


What we did

Built a seller console and an agentic loop around it.

1. Lead intake and intelligence

  • manual contact creation and CSV import;
  • lead card with pipeline statuses;
  • AI lead score with explanation (and heuristic fallback without API key);
  • research of public company websites (LinkedIn URLs are blocked in the research path);
  • discover leads via bridge: short profile browse (anti-ban pause) and immediately Connect;
  • network scan of 1st degree and separate outreach to your network (network_message) — separate job types.

2. Outreach copilot

AI prepares touch types: invite, first message, follow-up, network_message, incoming classification, and reply draft. Everything goes through a queue: Approve / Edit / Reject. The goal of the first touch in the playbook is to start a conversation, not to 'hard-sell the project'.

3. Sales CRM and overview

Status pipeline: new → qualified → invite_pending → connected → in_dialogue → meeting → opportunity → won/lost (+ suppressed). Dashboard: KPIs, pipeline, trend, attention tasks. Campaigns, playbook/persona from settings, suppression list.

4. Sending modes and safety

Default is approval. auto_send mode is enabled deliberately; sensitive content may remain on confirmation. In code: daily limits with a cap, risk presets (conservative / balanced / aggressive), kill switch, deny-list for dangerous account actions. Captcha / warning from the network → stop the loop.

5. Auto-comments (separate loop)

Separate comments tab: search/feed sources, topic filters, skip careers/politics, dedupe. Not mixed with the main message queue. Separate model for comments in config.

6. LinkedIn Bridge

Worker on Playwright + CDP to the seller's Chromium/Chrome profile. The profile and session remain yours; the bridge can run alongside on the seller's host or on a server in your environment — this is not 'logging in a cloud bot under someone else's name'. Admin UI and AI work without the bridge; invite / message / comment / discover (+ Connect) / network-scan / network_message go to LinkedIn only when the bridge is online.

sales-agent-ill-01-dashboard

sales-agent-ill-02-queue

sales-agent-ill-03-architecture-1

How it works technically

[ SvelteKit admin ]
        ↓
[ Go API + PostgreSQL 18 ]  ← OpenAI (score, drafts, classify, comments)
        ↓  outbox / jobs
[ Bridge: Node + Playwright CDP ]  ← host or server, seller session
        ↓
[ Chromium/Chrome profile → LinkedIn ]
Layer Role Stack
Admin UI Overview, leads, queue, comments, settings SvelteKit 3 · Svelte 5 · Vite
API / domain Auth, CRM, analytics, playbook, outbox Go 1.24 · pgx · HMAC sessions
AI Structured JSON responses, not 'free chat for chat's sake' OpenAI API (chat + separate comments model)
Bridge Executes actions in the seller's session via CDP Node · Playwright · CDP · Chromium/Chrome
Runtime Deploy api / web / (bridge) Docker Compose · GHCR images · Nginx · Postgres 18 · Redis (reserved)

What is intentionally absent (MVP): vector DB / RAG, multi-agent orchestration, self-hosted LLM, external CRM/Slack/email-outreach as a mandatory loop. Research — HTTP to public sites, not 'scraping LinkedIn Search for a database'.

Agent boundaries live in code (allow/deny, mode, limits), not only in the prompt. This is a separate engineering thesis of the product: safety by architecture.


Must / Not Now

Must

  • approve-first as default;
  • draft queue with edit/reject;
  • CRM pipeline up to meeting / opportunity;
  • AI scoring + generation of invite/message/follow-up/reply/network_message;
  • CDP bridge to the seller's session (host or server in your environment);
  • discover → short profile browse → Connect;
  • scan your network + network_message outreach;
  • limits, kill switch, risk presets;
  • campaigns / voice / playbook in settings;
  • separate auto-comments loop with filters;
  • delivery of api/web/(bridge) via Docker Compose and GHCR.

Not Now

  • handing the account to 'someone else's cloud bot' instead of CDP to your own session;
  • unsupervised mass-parsing of LinkedIn Search as the core of leadgen;
  • 'guarantee of ToS compliance' — social media automation always carries platform risk; in this case we talk about control engineering, not rule circumvention;
  • publication of secrets, Chrome profile paths, production leads, and personal data.

Conclusions

  1. For LinkedIn sales, the KPI 'invite accepted' without dialogue is a false goal; the system should pull toward meeting/opportunity.
  2. Approve-first teaches the playbook faster than immediate auto-send.
  3. The separation 'brains in the service / hands via CDP to your own session' reduces the risk class of someone else's cloud bots, but does not cancel the network's platform rules.
  4. Safety in code (deny-list, caps, kill switch) is more reliable than 'please be careful' in the prompt.
  5. Comments and direct messages are different queues and different risk models.

Checklist for a similar AI sales product

  • Fix ICP, language, and seller voice in settings, not in the article's hardcode
  • Default = approval; auto-send is a separate product decision
  • Outbox + idempotency of bridge actions
  • Limits and kill switch in code before the first run on a production account
  • Research only from public sources that can be explained to the client
  • What must not be exposed in the portfolio — as a list before screenshots

FAQ

What is an approve-first Sales Agent in this case?
Piplos Media implemented a Sales Agent in which AI prepares scoring and texts, and outgoing LinkedIn messages by default go only after the seller's Approve — until the team deliberately enables capped auto-send.

How is this different from a typical LinkedIn bot?
Actions go via CDP to your Chromium/Chrome session (bridge on the host or on a server in your environment). The service stores CRM, queue, and AI, but does not substitute the seller with someone else's cloud login. Plus deny-list and limits in code.

What is the product's stack?
Admin UI on SvelteKit, API on Go and PostgreSQL 18, generation on OpenAI API, action execution — Node/Playwright CDP, delivery — Docker Compose and GHCR images (api / web / bridge if needed).

Who is the product for?
For B2B teams with founder-led or seller-owned sales in LinkedIn, where personalization and account control matter. The pilot configuration — founders/CEO and custom software; market and voice change in Settings.

Can auto-send be enabled immediately?
Technically — yes, with auto_send mode. Product-wise it is recommended after drafts consistently pass manual acceptance; sensitive cases may remain on approve.

Is this circumventing LinkedIn rules?
No. The case describes engineering control (limits, stop on warning, human-in-the-loop). Social media automation always carries platform risk; the decision on the operating mode is on the account owner's side.

Is there RAG / a proprietary model?
In the described MVP — no: OpenAI API, structured JSON, playbook from the DB. Vector DB and self-hosted LLM are deliberately deferred.


CTA

If you need an AI sales loop with human-in-the-loop, CDP execution to your session, and a proper CRM pipeline — and not another cloud bot — we can break down your ICP and risk mode using the same scheme: approve-first → bridge → caps → only then automation.

Write to Piplos Media: a short discovery on an AI sales agent is usually faster than a month of manual spreadsheets and experiments 'on a live account without a safety net'.

The Result

The client received a working Sales Agent: from lead import and scoring to discover/Connect, outreach to their own network, a queue of personalized touches, and CRM up to the meeting. Seller control is preserved architecturally — a CDP bridge to your session and approve-first by default, while AI handles the routine of research and drafts. The system is delivered via Docker Compose and GHCR; the transition to auto-send is possible only behind strict limits and after text quality consistently passes manual acceptance. In the portfolio we record a verifiable engineering result — the loop composition and operating mode — without marketing KPIs that do not exist in measured form.