# MCP Server Diff (`conserving_mastodon/mcp-server-diff`) Actor

Monitor any Model Context Protocol server for change: each run snapshots the endpoint and diffs it against the last snapshot - tools added, removed, or changed, version bumps, latency drift. Schedule it and know the moment a dependency's contract moves. Charged only when a probe completes.

- **URL**: https://apify.com/conserving_mastodon/mcp-server-diff.md
- **Developed by:** [Chris Arsenault](https://apify.com/conserving_mastodon) (community)
- **Categories:** Developer tools, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$150.00 / 1,000 completed probe and diffs

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

## MCP Server Diff

**Know the moment an MCP server's contract changes.** Each run probes the endpoint (handshake, capabilities, full tool inventory), diffs it against the previous snapshot, and reports exactly what moved: tools added, tools removed, tool descriptions or input schemas changed, server or protocol version bumps, and initialize-latency drift. Schedule it hourly or daily against the servers your agents depend on, and stop discovering breaking changes in production.

### How it works

- First run stores a baseline snapshot (reported as `baseline_created`).
- Every later run probes fresh, compares by tool name and schema, updates the snapshot, and emits one row per change.
- State persists in a named key-value store on your account; the same URL can be tracked as separate streams with the `stateKey` input.

### Output

Summary row:

```json
{ "url": "https://example.com/mcp", "tools_count": 12, "tools_count_before": 11,
  "latency_delta_ms": 38, "change_count": 2, "note": "2 change(s) detected" }
```

Change rows:

```json
{ "kind": "tool_added", "tool": "export_report", "detail": "Exports a report..." }
{ "kind": "tool_changed", "tool": "search", "detail": "changed: input_properties, required" }
```

### Use cases

- **Agent builders**: schedule against every third-party MCP dependency; alert on `change_count > 0`.
- **Server authors**: outside-in release verification — did the deploy actually change what you meant to change, and nothing else?
- **Platform teams**: a contract-drift audit trail for the MCP surface you expose to internal agents.

Speaks streamable HTTP (JSON and SSE), protocol `2025-06-18`, read-only — it initializes, lists, and leaves; it never calls the server's tools. Endpoints that are down, not MCP, or auth-walled without a token report cleanly and **you are not charged**; billing is per completed probe, baseline runs included.

Built by 1450 Enterprises — the team behind the MCP Server Probe, which this Actor extends into continuous monitoring. Its first scheduled target is our own public library server.

# Actor input Schema

## `url` (type: `string`):

Streamable HTTP endpoint of the MCP server to monitor (e.g. https://example.com/mcp).

## `bearerToken` (type: `string`):

Sent as Authorization: Bearer for servers that require auth.

## `stateKey` (type: `string`):

Track the same URL as separate monitoring streams by giving each a distinct key.

## `timeoutSecs` (type: `integer`):

Per-request timeout for each protocol call.

## Actor input object example

```json
{
  "url": "https://gozerai.com/mcp/library",
  "timeoutSecs": 30
}
```

# Actor output Schema

## `results` (type: `string`):

First row: change count, tool counts before/after, latency delta, or baseline_created on the first run. Subsequent rows: each change (tool_added, tool_removed, tool_changed, version changes) with detail.

# 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 = {
    "url": "https://gozerai.com/mcp/library"
};

// Run the Actor and wait for it to finish
const run = await client.actor("conserving_mastodon/mcp-server-diff").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 = { "url": "https://gozerai.com/mcp/library" }

# Run the Actor and wait for it to finish
run = client.actor("conserving_mastodon/mcp-server-diff").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 '{
  "url": "https://gozerai.com/mcp/library"
}' |
apify call conserving_mastodon/mcp-server-diff --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,conserving_mastodon/mcp-server-diff"
        }
    }
}
```

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/IniSupda3bi7aPY9V/builds/tJUQSdei006gGxLCc/openapi.json
