{"uid":"cap_ZHUWGbaQB5q-iuBXezIHC","slug":"agent-dev-preflight-api-package-risk-check-b88ae562","name":"Agent Dev Preflight API – Package Risk Check","description":"Deterministic package risk preflight using OSV and registry metadata.","url":"https://agent-dev-preflight-api.bonkoturyu.workers.dev/v1/package/risk","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"package":{"type":"object","required":["ecosystem","name","version"],"properties":{"name":{"type":"string","maxLength":214,"minLength":1},"version":{"type":"string","minLength":1,"description":"Exact installed version; version ranges are rejected."},"ecosystem":{"enum":["npm","PyPI"],"type":"string"}},"additionalProperties":false}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.03","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_Kw-SOvMkJueolToQnpoSL","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns a deterministic risk assessment for an npm or PyPI package version using OSV vulnerability data and registry metadata.","exampleAgentPrompt":"Before I install it, can you run a risk preflight on lodash version 4.17.20 from npm and tell me if it has any known vulnerabilities or registry red flags?","exampleUseCases":[{"title":"CI pipeline dependency safety gate","prompt":"We're about to merge a PR that adds requests 2.28.0 from PyPI — can you do a risk preflight on it and flag any known vulnerabilities before we allow the merge?"},{"title":"Auditing a legacy project's pinned packages","prompt":"I've got an old package.json with express pinned at 4.17.1 on npm — can you check if that exact version has any OSV vulnerabilities or registry issues I should know about?"},{"title":"Vetting a newly discovered open-source library","prompt":"I just found a PyPI package called httpx at version 0.23.0 that I want to use — can you run a security preflight on it and tell me if it's risky to add?"}],"resultDescription":"A deterministic risk report for the specified package version, including OSV vulnerability matches, registry metadata signals (e.g. maintainer activity, publish anomalies), and an overall risk indicator — all scoped to the exact installed version provided.","failureModes":["Version range submitted instead of exact version — rejected with validation error","Package name or ecosystem not found in registry — returns not-found or error response","OSV data temporarily unavailable — upstream lookup failure","Invalid ecosystem value (only 'npm' and 'PyPI' are accepted) — schema validation error","Package name exceeds 214 character limit — rejected by input validation","Payment not provided or insufficient — 402 payment required response"],"whenToPreferThis":"Choose this endpoint when you need a fast, deterministic, per-version security check on a specific npm or PyPI package — especially in automated pipelines, CI gates, or agentic workflows where you want OSV vulnerability data plus registry metadata signals without spinning up a full SCA tool. Prefer it over general-purpose vulnerability scanners when you have an exact pinned version and need a lightweight, pay-per-call preflight with no setup.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T06:30:11.193Z","isFirstParty":false}