Metadata-Version: 2.5
Name: strand-mcp
Version: 0.4.0
Summary: MCP server for the Strand AI Platform — exposes upload / predict / job lifecycle to Claude, Cursor, and any other MCP-aware agent.
Project-URL: Homepage, https://strandai.com
Project-URL: Documentation, https://docs.strandai.com/sdks/mcp
Project-URL: Repository, https://github.com/Strand-AI/strand-official
Author-email: Strand AI <engineering@strandai.bio>
License: Apache-2.0
Keywords: anthropic,claude,h&e,mcp,pathology,spatial-omics
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Requires-Python: >=3.12
Requires-Dist: google-auth[requests]<3,>=2.40
Requires-Dist: httpx<1,>=0.27
Requires-Dist: mcp<3,>=2.0
Requires-Dist: strand-sdk<1,>=0.16.0
Requires-Dist: uvicorn<1,>=0.35
Provides-Extra: dev
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest>=8; extra == 'dev'
Requires-Dist: ruff>=0.6; extra == 'dev'
Description-Content-Type: text/markdown

# strand-mcp

Hosted MCP server for the [Strand AI Platform](https://strandai.com). Lets any
MCP-aware agent run H&E → spatial-proteomics inference end to end (browse,
upload, estimate or submit, monitor, and download) over an OAuth-authenticated
Streamable HTTP connection.

📚 **Full documentation: <https://docs.strandai.com/sdks/mcp>**

## Connect

Add a custom connector pointing at the hosted server URL
`https://mcp.strandai.com/mcp` (transport: Streamable HTTP), then authorize with
your Strand AI account and pick an organization. Step-by-step:
<https://docs.strandai.com/connectors/claude>.

There is nothing to install and no API key to manage. Slide bytes and results
never pass through the model or the server: `upload_slide` returns a presigned,
resumable upload session the agent PUTs bytes to directly, and the download
tools return short-lived signed links.

Agents can browse owned and public samples through one catalog, inspect owned
job history, update sample metadata, and estimate a run with
`submit_run(dry_run=true)` before reserving credits.

Research use only (RUO). Not for use in clinical or diagnostic procedures.

For programmatic or bulk workflows, use the
[Python SDK](https://docs.strandai.com/sdks/python) or
[REST API](https://docs.strandai.com/api/overview) instead.

## Analytics and privacy

The hosted server emits one `mcp_tool_called` operational event per tool
invocation. Its closed schema contains only the tool name, a static intent
enum, outcome, bounded latency, a coarse client enum, deterministic hashed
organization/user/OAuth-client pseudonyms, and a bounded failure category.
PostHog person/group profiles and GeoIP enrichment are disabled for these events.

The server never sends tool arguments or results, prompts, filenames, sample or
job IDs, marker names, slide data, credentials, OAuth tokens, signed URLs, raw
User-Agent values, exception names, or exception messages. Adding an analytics
property requires a code and privacy review; unrestricted argument capture is
forbidden.

MCP events use Strand's shared PostHog project. That project is currently
configured for **84 months of event retention**; its API reports
`events_retention_enforced=false`, and there is no shorter MCP-specific TTL.
This long shared retention is why the payload is minimized and identifiers are
one-way pseudonymized before ingestion. The project owner must reverify and
document any retention-setting change. Analytics are used only for product
reliability and aggregate connector usage; access is limited to Strand staff
with PostHog project access.

PostHog project tokens are public ingestion identifiers, so these events are
not a security audit log and can be forged by someone who obtains the browser
project token. Security, billing, and authorization decisions must use Strand's
server-side records instead. Analytics delivery is best-effort and adds at most
1.25 seconds to a tool response.

## Support

Email [support@strandai.com](mailto:support@strandai.com).

## License

Apache 2.0
