Skip to main content
TrackJud TrackJud
· Updated on · 14 min read

How to automate lawsuit search at a law firm

By TrackJud

Practical guide to automating per-CPF lawsuit lookup in a Brazilian law firm. 3 real paths (API integration, no-code, spreadsheet), real cost comparisons, and what the Bar Association and LGPD say. Updated April 2026.

TL;DR: Manual lawsuit search takes 30min-2h per CPF across 5 courts. Via API, 60 seconds. Firms of any size can automate without hiring a dev — there are 3 real paths (direct integration into case management software, no-code with Make/Zapier, or spreadsheet with Google Apps Script). Real API cost: R$ 20-60/month for a typical 100-CPF/month firm. ROI compared to manual paralegal: 30-50x. OAB allows it, LGPD has clear legal basis (art. 7º, §4º). This guide covers the 3 paths, real costs, 3 ready-to-copy workflows, what regulation says, and an 8-question FAQ.

Searching for lawsuits is one of the most repetitive activities at a law firm. According to the Justice in Numbers 2024 report from the CNJ (Brazilian National Justice Council), Brazil has more than 83 million active cases in court and 9.5% more new cases were filed in 2023 compared to the previous year — the highest litigation volume among all judicial systems in the world. In firms with active client portfolios, lawyers and paralegals spend dozens of hours per week accessing court websites, typing CPFs, and copying data into spreadsheets.

Worse: this manual work is error-prone, takes days, and doesn’t scale when the portfolio grows. At a firm with 200 active clients, just monthly monitoring of new cases consumes 3 to 5 full days of a dedicated paralegal’s time — and if the paralegal quits or gets sick, the workflow stops.

Automating this routine isn’t a luxury. It’s competitive survival for anyone who wants to scale without hiring proportionally. This guide covers the 3 real paths to automation (from most technical to simplest), real cost comparisons, workflows you can copy next week, and what OAB (Brazilian Bar) and LGPD (data protection law) say about it.

(If you still search manually and want to understand the current flow before automating, see the lawsuit search by CPF guide.)

The problem with manual search — what it really costs

Typical workflow without automation

A paralegal or lawyer doing manual lawsuit search follows a workflow everyone knows:

  1. Receives the request (new client, case analysis, due diligence, monthly monitoring)
  2. Opens the browser and navigates to the relevant court’s website (TJSP, TJMG, TJPE, etc)
  3. Types the client’s CPF
  4. Solves the captcha
  5. Manually navigates the results
  6. Copies each case into a spreadsheet
  7. Repeats for the next court (if the client operates in other states)
  8. Repeats for the appellate instance
  9. Consolidates everything into a document or report

Average time for 1 CPF across 5 courts: 30 minutes to 2 hours, depending on client complexity and system availability. For 10 clients: 1 to 2 full workdays. For a 200-client portfolio, monthly monitoring consumes 30-50 hours of work — nearly what a full-time dedicated person would produce.

Inefficiency isn’t just about time. It comes from 5 structural problems that no paralegal training can solve:

ProblemImpactWhy it happens
Captchas+30s-2min per queryEach court has its own captcha, some requiring image recognition
Court instabilityComplete rework when the site goes downLegacy systems from 2008-2015, no redundancy
Different formatsEvery result needs to be reformattedESAJ, PJe, EPROC, Tucujuris — each returns its own layout
Human errorMissed search, wrong CPF, typosFatigue, rush, lack of systematic review
Zero scalabilityVolume doubles, time doublesLinear work — 100 CPFs cost 100x the time of 1

The last problem is critical. At a firm that tripled its portfolio in 2 years (common for growing firms), time spent on lawsuit search triples too. Either you triple the team (increasing fixed cost) or you automate (cost stays almost constant).

A real case — mid-sized firm with 280 clients

To ground the problem: a mid-sized firm specializing in credit recovery, with a 280-active-client portfolio, tallied how much they spent on manual search monthly before automating. The numbers:

  • Dedicated paralegal: 18h/week on search = 72h/month
  • Junior lawyer reviewing: 6h/week = 24h/month
  • Direct cost (salary + pro-rata benefits): ~R$ 4,200/month
  • Indirect cost (partner time when something broke out of flow): 3-5h/month
  • CPFs searched: ~500/month
  • Average cases found: ~180
  • Errors caught in later review: 8-12% of searches had a missing court or poorly copied result

That firm automated the workflow in 3 weeks (without hiring a dev) and the same paralegal now processes 2,000 CPFs/month, with no query errors, and the junior lawyer was reallocated to procedural viability analysis — the part that actually has legal value.

What “automating” actually means in practice

Automating lawsuit search means replacing the manual flow with a software call that returns structured data. Technically: you make an HTTP request to an API, passing the CPF and the list of courts, and receive a JSON with all cases found.

In practical terms for the lawyer:

  • Instead of 2 hours navigating websites, you click a button and wait 60 seconds
  • Data comes back standardized (same format across all courts)
  • Captchas are solved automatically
  • Trial and appellate instances are queried together
  • If a court fails, the system retries
  • You get an auditable log of each attempt (relevant for case law on system unavailability)

This doesn’t require the lawyer to become a programmer. There are 3 main paths to automation, from most technical to simplest. Pick the one that fits your firm.

Path 1 — Direct integration into case management software

Firms that use case management software like Projuris, Astrea, Legal One, ADVBox, Aurum, SAJ ADV, Themis can integrate a lawsuit search API directly into the flow. This requires:

  • A developer (in-house or contracted) to connect the API to the software
  • A “Search cases” button on the client’s page inside the software
  • When the lawyer clicks, the software calls the API and populates the page with found cases

Advantage: fully integrated flow, no context-switching out of the firm’s software. The paralegal clicks, the cases appear.

Disadvantage: requires software customization. Not all systems allow API integration — more closed software (SAJ ADV is the classic example) rarely accepts custom extensions.

When it makes sense: firms with high volume (≥ 500 searches/month) and software that accepts API or webhook integration. The initial investment (~R$ 3,000-8,000 for a dev to integrate) pays off in 2-3 months.

If the software you use accepts webhooks or has third-party API support, it’s worth asking the vendor for an integration with Vigilant’s API. Since Vigilant is REST + JSON documented in OpenAPI 3.1, any dev can integrate in a few hours. See developer resources with examples in cURL, Python, Node.js, and Go.

Path 2 — No-code tools (Make, Zapier, n8n)

For firms without a technical team, no-code tools let you automate without writing code:

  • Make (formerly Integromat): visual drag-and-drop interface, generous free tier, ideal for starting
  • Zapier: more internationally popular, more expensive, simpler interface than Make
  • n8n: open-source, self-hosted, more powerful but requires server setup
  • Pipedream: free alternative with generous limits

Example Make workflow (20 minutes to configure):

  1. Trigger: a row is added to the “New clients” spreadsheet
  2. Action 1: call Vigilant’s API passing the row’s CPF
  3. Action 2: receive the JSON with cases
  4. Action 3: write the results to another tab of the spreadsheet
  5. Action 4: send an email to the responsible lawyer with the summary

This kind of workflow takes 1 hour to build, runs automatically, and the lawyer just inputs the CPF and receives the data via email. For firms using Google Sheets, it’s worth reading the dedicated guide on Vigilant + Google Sheets integration with the complete walkthrough.

When it makes sense: small to mid-size firms (50-300 clients), no dev, already using Google Workspace or Microsoft 365. Monthly additional cost: R$ 0 (Make free tier) to R$ 50 (basic plan) + R$ 20-60 from the Vigilant API.

Path 3 — Spreadsheet + script (the simplest route)

For firms that already work in Excel or Google Sheets, you can call the API directly from the spreadsheet using:

  • Google Apps Script (Google Sheets) — simple JavaScript, runs in the cloud, free
  • Power Query (Excel) — connects to REST APIs natively
  • VBA (Excel — legacy but works) — for firms still using desktop Excel

The idea is to create a custom function in the spreadsheet, like =SEARCH_CPF(A2, "TJSP,TJMG"), that calls Vigilant’s API and returns the total cases for that row. Lawyers with basic scripting knowledge can build this kind of spreadsheet in an afternoon.

The official API documentation is the starting point: it explains endpoints, schemas, and authentication, with call examples in cURL, Python, and JavaScript. You test requests directly in the interactive Scalar UI (PT/EN) and then adapt the example to your environment — Apps Script, Power Query, or another tool.

When it makes sense: firms with 1-20 clients already using a master spreadsheet that just want to eliminate manual data entry. Cost: R$ 0 (Apps Script is free) + API usage.

Real workflows to copy — 3 concrete examples

Workflow 1 — New client onboarding

Manual: lawyer receives the CPF, opens 5 courts, searches, copies data, builds a report — 1 to 2 hours.

Automated: lawyer fills the CPF in a form (Google Form) → Make triggers → Vigilant searches → results drop into the shared spreadsheet → automated PDF report → email to the responsible lawyer. Lawyer’s time: 30 seconds.

Application: litigation firms that want to qualify the client before the first meeting. The lawyer enters the meeting already knowing how many active cases the potential client has, in which chambers, with aggregate case values.

Workflow 2 — Supplier due diligence (labor)

Manual: the legal department searches the supplier’s CNPJ in labor, civil, and tax courts, then searches the CPFs of the partners (obtained from the Federal Revenue), in each court — 3 to 5 hours per supplier.

Automated: spreadsheet with the list of suppliers to verify → script runs overnight → in the morning, consolidated report with all cases found, alerts flagged in red for high-risk suppliers. Lawyer’s time: 15 minutes of analysis instead of days of research.

Application: firms doing supplier auditing for companies subject to TST Súmula 331 (subsidiary liability). Topic covered in depth in the post Labor liability and Súmula 331.

Workflow 3 — Portfolio monitoring (the most valuable workflow)

Manual: every quarter, the firm needs to re-search all clients to verify new cases. In a 200-client portfolio, this consumes 3 to 5 days of paralegal work. Result: the firm only does monitoring 4 times per year.

Automated: script runs automatically every Saturday night, searches all portfolio CPFs, compares with last result, and sends an email with “new cases since last week”. Lawyer’s time: zero during the week, 10 minutes reading the email on Monday morning.

This kind of continuous monitoring is impossible manually and is one of automation’s biggest value drivers. The post Lawsuit monitoring with CPF alerts details the full architecture.

How much it costs — automate vs hire

The math is what convinces any skeptical partner. Real comparison table:

ScenarioMonthly costCapacityScalabilityError rate
Paralegal doing manual searchR$ 1,500-2,500~50 CPFs/monthLinear (doubling CPFs = hire another)8-12%
Junior lawyer doing manual searchR$ 5,000+Loss of billable hoursLinear4-8%
Closed legal software w/ integrationR$ 300-1,500/month (fixed plan)Depends on planSemi-linear<2%
Vigilant (pay-per-use API)R$ 20-200/month200-2,000 CPFs/monthPay-as-you-go<1%

For a small firm running 100 searches per month, Vigilant costs around R$ 50 monthly (100 × 5 courts × R$ 0.10). Compared to a paralegal’s cost or the lost lawyer time, it’s irrelevant. Full pricing at /en/pricing/.

For a mid-sized firm running 1,000 searches per month, cost is around R$ 500 — still 3-5x cheaper than keeping a paralegal dedicated exclusively to the task, without counting quality gains.

Important point: Vigilant has automatic 2-day cache. If you query the same CPF in the same court twice within 48h, the second query is free. This further reduces real cost for firms with repeated workflows.

What OAB and LGPD say

OAB — Provimento 205/2021

Provimento OAB 205/2021 governs legal advertising — it doesn’t prohibit internal automation of research. Lawsuit queries are about public court data, and using technology to access public data is a perfectly lawful operational activity. The Bar Association actually encourages technology adoption by lawyers via the Estatuto da Advocacia and the CNJ itself.

The only real restriction is not using the data for unsolicited outreach (improper client solicitation). If you automate to serve existing clients, manage ongoing cases, or do contracted due diligence, you’re 100% within permitted use.

LGPD — Law 13.709/2018

Public court data has clear legal basis for processing under Brazilian data protection law:

  • Art. 7º, §4º: “consent is dispensed for data made manifestly public by the subject”
  • Art. 7º, VI: “for the regular exercise of rights in judicial, administrative, or arbitration proceedings”
  • Art. 7º, IX: “when necessary to meet the legitimate interests of the controller or a third party”

The lawsuit searches you automate fit all three. The data is manifestly public (published by the court), the use is legitimate (practice of law), and it relates to the firm’s operational activity. Keep per-query audit logs (Vigilant’s API does this automatically) and you have an auditable trail for any challenge.

How to start — practical checklist

1. Test before integrating

Create a free Vigilant account and get 5 free credits. Search 1 CPF across 5 courts through the web dashboard and see the returned data. Without writing a line of code. This validates that coverage matches your courts of interest before any investment.

2. Pick the right path for your firm

  • Has internal tech team: direct integration into case management software
  • Uses Google Sheets or Excel: Apps Script or Power Query
  • Wants visual automation without code: Make or n8n
  • Wants to delegate to software vendor: open a ticket asking for official Vigilant API integration

3. Start with the workflow that hurts most

Identify the most repetitive and time-consuming task at your firm. Usually one of these (in order of average ROI):

  1. Portfolio monitoring (highest ROI — no one does this manually)
  2. New client onboarding (high frequency)
  3. Supplier due diligence (high complexity)
  4. Opposing party background check (low frequency, high value)

Automate that task first, validate, expand.

4. Iterate — automation isn’t “all or nothing”

Start simple, validate it works, then sophisticate. A basic 1-hour setup workflow already eliminates 80% of the manual work. A common mistake is trying to automate everything at once and getting stuck in scope creep. Focus on one workflow, ship it, measure, learn, expand.

Glossary

TermDefinition
APIApplication Programming Interface — software interface allowing one program to call another via HTTP
RESTRepresentational State Transfer — HTTP-based API standard used by most modern APIs
JSONJavaScript Object Notation — data exchange format returned by the API
OpenAPIAPI documentation standard. Vigilant’s is version 3.1
WebhookNotification mechanism — system A tells system B when something happens
No-codeVisual tool for automating without writing code
Rate limitRequests-per-minute limit the API accepts
CacheTemporary storage — result reused when the same query is repeated

Conclusion

Automating lawsuit search is the most obvious productivity gain for any law firm in 2026. The problem isn’t technical — the tools exist, are accessible, and regulation (OAB, LGPD) is clear. The problem is that many firms still don’t know the 3 paths described here exist.

If your firm still searches manually, you’re spending lawyer time (R$ 300-500/h) on a task that costs R$ 0.10. Worse: you’re losing clients to firms that deliver reports in minutes instead of days.

Start small. Automate one workflow. Measure the return. Expand.

If you want to see the full commercial layer — what changes at a firm that adopts this stack — check our law firms solutions page. And if you want to validate that Vigilant covers the courts where you practice, the full list is at /en/courts/.


Want to automate lawsuit search at your firm? 5 free credits on signup, no credit card. Start now.

Frequently asked questions

Do I need a developer to automate lawsuit search?

Not necessarily. It depends on the path you choose. Direct integration with your case management software (Projuris, Astrea, Legal One) does require a developer to connect the API. But no-code tools like Make, Zapier, and n8n let you automate without writing code — you drag visual blocks. And for firms that already work in Google Sheets, you can call the API with Google Apps Script or Power Query (Excel), both accessible to lawyers with basic scripting knowledge. Our recommendation: start with the no-code path (Make or spreadsheet), validate the workflow, and only invest in a dev when volume justifies it.

Does it work with the case management software I already use (Projuris, Astrea, Legal One, SAJ ADV)?

Depends on the software. Projuris, Astrea, ADVBox, and Legal One accept third-party API integration — you request customization from the vendor or hire a dev. SAJ ADV (Softplan) is more closed and rarely allows custom integrations. For cases where the software is locked down, the alternative is running automation OUTSIDE the software (Google Sheets, Make) and importing results afterward — less elegant but it works. If your firm's volume is high enough, open a ticket with the vendor requesting integration.

How much does it cost to automate vs. having a paralegal do it manually?

A junior paralegal costs R$ 1,500-2,500 per month and manually processes ~50 CPFs per month, with errors. The Vigilant API costs R$ 0.10 per query per court — a firm making 100 searches per month across 5 courts each spends R$ 50 monthly. The difference is 30-50x in favor of automation, not counting the opportunity cost of the lawyer's time reviewing paralegal work. Important: automation doesn't 100% replace the paralegal — it frees their time for actual legal analysis, which is where the value lives.

Is it legal under Brazilian Bar Association rules to automate lawsuit search?

Yes. OAB Provimento 205/2021 governs legal advertising — it doesn't prohibit internal automation of research. Lawsuit queries are about public court data, and using technology to access public data is a perfectly lawful operational activity. The Bar Association actually encourages technology adoption by lawyers. The only real restriction is not using the data for unsolicited outreach (improper client solicitation), which is a use-case question, not a query question.

Does automation make sense for small firms, with fewer than 50 clients?

Yes — and it may matter more for small firms than for large ones. The math is simple: even with 30 clients, monthly portfolio monitoring manually consumes 10-15 hours from a partner or paralegal. Automated, those 15 hours become 30 minutes of result analysis. And for small firms without a dedicated paralegal, those 15 hours belong to the partner themselves — time worth R$ 300-500/hour in billable work. Spending R$ 30-60/month on API to free up 15h of partner time is 50-100x ROI.

What happens if a court is down when the API is called?

Vigilant's API has automatic retry policy — if the court doesn't respond, the system tries again a few times before erroring. If the court stays down permanently during the day, the job becomes 'unavailable' and you can hit the reprocess endpoint later. The important part: you always have an auditable log of attempts, which matters for Brazilian case law on system unavailability (see the [ESAJ vs PJE guide](/en/blog/esaj-vs-pje/) on this topic). Manually, this robustness simply doesn't exist — if a court website goes down, the lawyer can't search, period.

Does the API cover the 24 main courts in Brazil?

Vigilant currently covers 12 judicial sources across 10 Brazilian states, including the 3 largest: TJSP (25% of all cases in the country), TJRJ, and TJMG. Full coverage is at [/en/courts/](/en/courts/) with each court's status. We don't cover 100% of courts yet — and when a CPF needs a court outside coverage, the lawyer searches that one manually. The hybrid path (90% automated, 10% manual) is already much better than 100% manual.

Do I need to automate EVERYTHING at once, or can I start small?

Start small. Our recommendation is to automate the most painful workflow first (usually monthly portfolio monitoring or new client onboarding), validate that it works, measure the time savings, then expand. Automation isn't binary — a 1-hour no-code workflow already eliminates 80% of the manual work in that specific flow. You can add more workflows over time as ROI confirms itself.

Related articles