# OSV Open Source Dependency CVE Scanner (`deepaksheoran172/osv-dependency-cve-scanner`) Actor

Scan software packages across npm, PyPI, Go, and Maven for known CVEs using Google's official OSV.dev vulnerability database.

- **URL**: https://apify.com/deepaksheoran172/osv-dependency-cve-scanner.md
- **Developed by:** [Deepak Sheoran](https://apify.com/deepaksheoran172) (community)
- **Categories:** Developer tools
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$3.00 / 1,000 extracted data record / events

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## OSV Open Source Dependency CVE Scanner

> **Canonical Approved Idea #2** | Cluster: `A · Supply chain` | Tier `3`\
> **Official Data Source:** `Google OSV.dev Vulnerability API` (https://api.osv.dev/v1/query)\
> **Target Buyer:** Dev teams, AppSec, CI owners\
> **Job-To-Be-Done:** Paste package name and version, get CVEs, fixed versions, and severity

***

### 🤖 AI Agent & MCP Tool Integration

Use this tool when you need real-time, deterministic, structured data for `osv-dependency-cve-scanner` without maintaining headless browsers or managing proxies.

- **MCP Tool Name**: `osv-dependency-cve-scanner`
- **Pricing**: Pay-Per-Event (PPE) at `$0.003` per verified `result-item`. Free tier runs available on Apify Cloud.
- **Input Parameters**: Fully configurable via JSON schema (all parameters have verified defaults).
- **Output Format**: Clean JSON / CSV formatted dataset records conforming to standard schemas.

### What It Does

Scan software packages across npm, PyPI, Go, and Maven for known CVEs using Google's official OSV.dev vulnerability database.

#### Why This Actor vs Raw Source API

- **Pre-Normalized & Enriched:** Converts raw upstream responses into uniform, RFC-compliant JSON records with UTC timestamps.
- **Zero Infrastructure Overhead:** Run ad-hoc or on a recurring schedule without managing cloud servers, API keys, or rate-limit backoffs.
- **Built-in Enterprise Security:** Built-in SSRF protection, IP verification, and CSV formula injection sanitization.

***

### Transparent Pay-Per-Event (PPE) Pricing

- **Free Preview Tier:** First **10 qualifying records free** per run.
- **Paid Rate:** **$0.003 per qualifying record** ($3.00 per 1,000 records).
- **Zero Charge Guarantee:** No charges for empty runs, network failures, or invalid inputs.

***

### Input Parameters

| Parameter | Type | Required | Description | Default / Example |
|---|---|---|---|---|
| `packageName` | `string` | Yes | Package identifier (e.g. lodash, requests) | `lodash` |
| `ecosystem` | `string` | No | Ecosystem (npm, PyPI, Maven, Go) | `npm` |
| `version` | `string` | No | Target version string | `4.17.20` |
| `maxItems` | `integer` | No | Maximum records to return | `10` |

***

### Output Fields

| Field | Type | Provenance | Description |
|---|---|---|---|
| `vulnId` | `string` | `DIRECT_SOURCE` | OSV / CVE Identifier |
| `packageName` | `string` | `DIRECT_SOURCE` | Target package name |
| `ecosystem` | `string` | `DIRECT_SOURCE` | Package ecosystem |
| `summary` | `string` | `DIRECT_SOURCE` | Vulnerability summary |
| `details` | `string` | `DIRECT_SOURCE` | Full advisory details |
| `published` | `string` | `DIRECT_SOURCE` | Publication timestamp |
| `aliases` | `array` | `DIRECT_SOURCE` | CVE aliases (e.g. CVE-2021-23337) |

***

### Truth-in-Advertising & Boundaries

> \[!IMPORTANT]
>
> - **Authoritative Source:** Data is retrieved directly from `Google OSV.dev Vulnerability API` without synthetic generation.
> - **Availability:** Subject to official upstream server availability and rate limits.
> - **No Legal Advice:** Regulatory and sanctions records are provided for operational intelligence and do not constitute formal legal counsel.

### 💰 Transparent Pay-Per-Event (PPE) Pricing

This Actor operates under Apify's **Pay-Per-Event (PPE)** monetization model:

- **Primary Event**: `result-item`
- **Rate**: `$0.003` per successfully extracted and delivered data record.
- **Zero-Charge-on-Error Guarantee**: You are **never charged** for empty results, network errors, timeouts, or diagnostic logs.
- **Free Preview Available**: Test runs on Apify Cloud allow free initial evaluations before scaling.

# Actor input Schema

## `packageName` (type: `string`):

Package identifier (e.g. lodash, requests)

## `ecosystem` (type: `string`):

Ecosystem (npm, PyPI, Maven, Go)

## `version` (type: `string`):

Target version string

## `maxItems` (type: `integer`):

Maximum records to return

## Actor input object example

```json
{
  "packageName": "lodash",
  "ecosystem": "npm",
  "version": "4.17.20",
  "maxItems": 10
}
```

# Actor output Schema

## `datasetItems` (type: `string`):

Export URL of extracted dataset records.

## `summaryJson` (type: `string`):

JSON execution metrics.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "packageName": "lodash",
    "ecosystem": "npm",
    "version": "4.17.20",
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("deepaksheoran172/osv-dependency-cve-scanner").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "packageName": "lodash",
    "ecosystem": "npm",
    "version": "4.17.20",
    "maxItems": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("deepaksheoran172/osv-dependency-cve-scanner").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "packageName": "lodash",
  "ecosystem": "npm",
  "version": "4.17.20",
  "maxItems": 10
}' |
apify call deepaksheoran172/osv-dependency-cve-scanner --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,deepaksheoran172/osv-dependency-cve-scanner"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/2VbaYxaDOiUhNF8pe/builds/aaZl8ZAkDC4tlATy5/openapi.json
