Skip to content
Automation & IntegrationsBeginnerFor builders6 min read

Premium guide — free while we launch

Normally ₹999. No card, no signup — read online or save the PDF.

Connect Your Tools: Sheets, CRM, Slack, Telegram

An AI agent that can't reach your other tools is just a clever chatbot. This guide shows you, step by step, how to wire an agent into Google Sheets, your CRM, and Slack or Telegram so it can read data, write records, and ping you when something needs a human. No heavy engineering required.

How agents actually talk to other tools

Every integration boils down to three patterns. Knowing which one you need saves hours.

MethodWhat it isBest forWatch out for
API callYour agent sends an HTTP request to a tool (Sheets, HubSpot, Razorpay) and gets data backReading/writing records on demandRate limits; you handle auth
WebhookA tool pushes an event to your agent's URL the moment something happens"When a new lead arrives, do X"Your endpoint must be public and verify the sender
No-code connectorZapier, Make, or n8n sits between the two and does the plumbingSpeed, non-developers, glue between 5+ appsPer-task cost; another point of failure

A simple rule: if you're a builder shipping fast, start with a no-code connector for low-volume glue (a few hundred events a day) and graduate to direct APIs + webhooks when volume or cost makes the connector hurt. Most agents on /listings use webhooks to receive events (a WhatsApp message, a new order) and direct API calls to act (update a sheet, post to Slack).

If you're still building the agent itself, read /guides/build-your-first-ai-agent first, then come back here for the wiring.

Google Sheets as a lightweight database

For a solo founder or small team, a Google Sheet is a perfectly good database for the first few thousand rows: leads, orders, FAQs, a content calendar. It's free, your team already knows it, and you can eyeball the data.

Set it up in 10 minutes:

  1. Create a sheet with a clear header row (timestamp, name, phone, query, status).
  2. Create a Google Cloud service account, download its JSON key, and share the sheet with the service account's email (it ends in ...iam.gserviceaccount.com). This is the step everyone forgets.
  3. Use the Sheets API values.append to add rows and values.get to read them.

Use it for:

  • Capturing every WhatsApp/Telegram conversation an agent handles (one row per lead).
  • A read-only "knowledge" tab the agent checks before answering (prices, GST rates, return policy).

Stop using it when: you cross ~5,000 active rows, need two people writing at once, or need to query "all unpaid orders from last week" fast. That's your signal to move to a real database (Postgres, Airtable, or your CRM).

One row should mean one thing. Don't cram a chat log into a single cell — you'll regret it when you try to filter.

CRM sync without breaking your pipeline

Your CRM (Zoho, HubSpot, Freshsales, or even a Sheets-based pipeline) is where deals live. The cardinal sin is letting an agent create duplicate contacts or overwrite a sales rep's notes. Three rules keep you safe:

  1. Match before you create. Always look up by phone or email first (phone is king for Indian customers). Only create a new contact if the lookup returns nothing. UPSERT, never blind INSERT.
  2. Write to a staging field, not the source of truth. Let the agent fill a lead_source = "AI agent" and a notes field. Don't let it change deal stage or owner — that's a human decision.
  3. Make writes idempotent. Include a unique key (like the WhatsApp message ID) so a retried webhook doesn't double-post.

A safe sync direction for most teams: agent writes new leads + enriches notes; humans own stage, value, and ownership. Run a nightly reconciliation that flags any contact the agent touched in the last 24 hours so your sales lead can review.

Slack and Telegram as control panels and alerts

These are your agent's cockpit. Two distinct jobs:

  • Alerts (one-way): "New ₹4,999 order from Priya", "Agent couldn't answer this — needs a human", "Razorpay payment failed". A Slack incoming webhook or a Telegram bot message does this in one HTTP POST.
  • Control panel (two-way): Approve a refund, mark a lead as won, or pause the agent — straight from a chat button. Slack uses interactive buttons + a request URL; Telegram uses an inline keyboard with callback queries.

For Indian small teams, Telegram is often the better control panel: free, no per-seat cost, great mobile app, and your ops person likely already lives there. Slack wins if your team is already on it.

A practical pattern: route alerts to a channel and approvals to a thread/DM so the noise doesn't drown the decisions. Set a "human handoff" trigger so any message the agent scores as low-confidence lands in Slack with a one-tap "I'll take it" button.

Auth and keys without leaking them

This is where guides go quiet and breaches happen. Do not skip it — under the DPDP Act, leaking customer data via a hardcoded key is your liability.

  • Never put API keys, tokens, or the Sheets JSON in your code or a public repo.
  • Store every secret in environment variables or a secrets manager (Railway/Render/Vercel env, Doppler, or your host's vault).
  • Give each integration its own key, scoped to the minimum it needs (a Sheets key shouldn't touch your CRM).
  • Verify every webhook's signature (Slack signing secret, Razorpay webhook signature) before trusting the payload — otherwise anyone who finds your URL can spoof events.
  • Rotate keys on a calendar reminder, and immediately if a contractor leaves.
  • For multi-step OAuth tools, store the refresh token, never the user's password.

If you're selling a hosted agent on AgentDukaan, this matters even more: buyers' secrets must never end up in your code or logs. See /guides/production-ready-agent-checklist before you ship.

A starter integration recipe

Let's wire a real one end to end: a WhatsApp lead-capture agent that logs to Sheets, upserts your CRM, and pings Telegram.

  1. Trigger: Customer messages your WhatsApp number. The webhook hits your agent.
  2. Understand: The agent extracts name, intent, and budget from the message.
  3. Log: values.append one row to your Leads sheet (timestamp, name, phone, query, status=new).
  4. Sync: Look up the phone in your CRM → if absent, create contact with lead_source = "WhatsApp AI"; if present, append a note.
  5. Alert: POST to Telegram: "New lead: Priya, budget ₹15k, asking about caption-writer agent." with an inline "Assign to me" button.
  6. Reply: The agent answers the customer in WhatsApp.

To get clean extraction in step 2, paste this prompt into your agent:

You are a lead-intake parser for an Indian small business.
From the customer message below, extract a JSON object with exactly
these keys: name, phone, intent, budget_inr, language, urgency.

Rules:
- phone: digits only, no +91 or spaces. If none, use "".
- budget_inr: integer rupees, or null if not stated. "15k" => 15000.
- language: "english", "hindi", or "hinglish".
- urgency: "low" | "medium" | "high".
- Return ONLY valid JSON. No commentary, no markdown fences.

Customer message:
"""
{{message}}
"""

Build the no-code version first in Zapier or Make to prove the flow, then move the high-volume steps to direct API calls once it's earning. Tighter, channel-specific copy lives in /guides/whatsapp-support-prompt-pack.

Next steps

  • Create your Leads sheet and share it with a service account today.
  • Set up one Telegram bot and send yourself a test alert (15 minutes).
  • Move every key out of your code into environment variables before you ship.
  • Run the recipe above as a no-code flow, then graduate the busy steps to APIs.

If wiring it yourself isn't where you want to spend your week, browse pre-integrated agents on /listings — many already ship with Sheets, CRM, and Telegram connectors — or check the /help center when you get stuck.

More in Automation & Integrations

Want the agent, not just the guide?

Browse ready-made AI agents or list your own on AgentDukaan.