# pkgpulse PyPI Preflight Check

> pkgpulse PyPI Preflight Check is a paid API for AI agents from pkgpulse.letom1176.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-30).

Checks whether a PyPI package name exists, detects typosquatting and hallucinated names, and returns a safety verdict before installation.

## Facts

- Endpoint: GET https://pkgpulse.letom1176.workers.dev/api/pypi-check?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-30
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pkgpulse-pypi-preflight-check-63a5934e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_V3_DrLpPVbyITEHsnYobo

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability pkgpulse-pypi-preflight-check-63a5934e
```

Example prompt: Before I add it to requirements.txt, check whether 'reqeusts' is a real PyPI package or a typo — and let me know if it looks like a typosquat of anything popular.

## When to prefer this

Use this endpoint when you need a fast, single-package PyPI existence and typosquat check — especially when validating package names generated by AI coding assistants or received from untrusted sources. Prefer it over general OSV vulnerability scans when the primary concern is whether the package name itself is legitimate, not whether it has known CVEs.

## Known failure modes

- Missing 'name' query parameter returns a validation error
- Network timeout from PyPI API upstream causes a 502 or error response
- Very obscure packages may have limited lookalike data
- Version specifier syntax errors may cause unexpected behavior
- Payment failure via x402 returns 402 with payment details before any data is returned

## How this service works

Dependency intelligence for AI coding agents, paid per-call via x402 (USDC on Base): npm package health scores with a disclosed rubric, typosquat checks, dependency audits, OSV known-vulnerability scans (npm, PyPI, Go, crates.io, Maven and more) and PyPI preflight checks. Free index at /, free sample at /api/sample.

## Output

Returns a JSON object with: whether the package exists on PyPI, a verdict string (e.g. 'stop', 'caution', 'ok'), a human-readable headline explaining the finding, and a lookalike object listing close matches by edit distance along with their 30-day download counts and an overall risk level.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "name"
     ],
     "properties": {
      "name": {
       "type": "string",
       "description": "PyPI project name, e.g. requests"
      },
      "version": {
       "type": "string",
       "description": "Optional PEP 440 pin or specifier (==2.31.0, >=2.28,<3). Omit for latest"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "name": "reqeusts",
  "exists": false,
  "verdict": "stop",
  "headline": "reqeusts is NOT on PyPI. It resembles requests: likely a typo or a hallucinated name.",
  "lookalike": {
   "matches": [
    {
     "popular_name": "requests",
     "edit_distance": 1,
     "popular_downloads_30d": 1208056002
    }
   ],
   "risk_level": "medium"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pkgpulse-pypi-preflight-check-63a5934e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from pkgpulse.letom1176.workers.dev](https://www.zero.xyz/host/pkgpulse.letom1176.workers.dev/llms.txt)
