court-sms

Parses court delivery SMS messages, downloads legal documents, and archives them into case directories.

636|91|Updated Jan 7, 2026
One-click install
npx skills add https://github.com/cat-xierluo/legal-skills --skill court-sms
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: court-sms
Source: https://github.com/cat-xierluo/legal-skills/tree/main/skills/court-sms
Command: npx skills add https://github.com/cat-xierluo/legal-skills --skill court-sms

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires playwright, pypdf, and includes references (resource) components.

What problem does it solve?

Lawyers frequently receive court SMS notifications (document delivery, filing notices, hearing reminders) and must manually open delivery platform links, download PDFs, rename them, and file them into the correct case folder. This Skill automates that entire pipeline from pasted SMS text to archived document.

Core Features & Use Cases

  • SMS Parsing & Case Matching: Extracts case numbers, parties, and download links from court SMS text, then matches or auto-creates the corresponding case directory.
  • Multi-Platform Document Download: Supports five Chinese court delivery platforms (zxfw, gdems, jysd, hbfy, sfdw) with a strict serial fallback chain: curl API direct download, Playwright CLI, then Playwright MCP browser automation.
  • Archiving & Deadline Alerts: Renames and files documents into case folders, writes structured JSON archive records, highlights summons hearing details, and auto-calculates appeal deadlines for judgments and rulings.
  • Use Case: Paste a delivery SMS from a court, and the Skill downloads all served documents, files them under the matched case folder, and reports the hearing date or appeal deadline.

Quick Start

Paste the court SMS text or delivery link and ask the assistant to download and archive the served documents into the matching case directory.

Frequently Asked Questions about court-sms

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I download court documents from a delivery SMS link?

Paste the full SMS text or just the delivery URL. The Skill extracts parameters like qdbh, sdbh, and sdsin, calls the platform API with curl to get signed download links, and saves the PDFs to a staging directory before archiving.

Which court delivery platforms are supported for document download?

Five platforms are supported: zxfw.court.gov.cn (national), sd.gdems.com (Guangdong), jysd.10102368.com (postal delivery), dzsd.hbfy.gov.cn (Hubei), and sfpt.cdfy12368.gov.cn (judicial delivery network). Unknown domains are identified by URL path patterns.

Does downloading court documents require a browser or Playwright?

Usually not. The national zxfw platform works via direct curl API calls with no browser. Playwright CLI or MCP is only needed for platforms without public APIs (gdems, jysd, sfdw) or when the API approach fails.

How is the appeal deadline calculated for judgments?

When a judgment or ruling is detected, the deadline is computed from the service date (dt_cjsj from the API response): 15 days for civil and administrative judgments, 10 days for civil rulings and criminal judgments, and 5 days for criminal rulings.

What happens if no matching case directory exists?

The Skill automatically creates a new case directory named with the case number and parties under the current project root, without asking for confirmation. Downloaded documents are then filed into that new directory.

What sensitive data does this Skill store locally?

It writes the raw SMS text, case numbers, parties, court identifiers, download parameters, and API responses into a local archive/ directory as JSON records. This directory is gitignored by default and should not be synced to public repositories.