Skip to main content

Armature analytics wrapper SDK for Python MCP servers.

Project description

armature-mcp-analytics

Armature analytics for Python MCP servers. The v1 integration is FastMCP-first: instrument a FastMCP instance, keep writing normal tools, and Armature records tool calls with MCP-specific telemetry.

Install:

pip install "armature-mcp-analytics[fastmcp]"
import os
from fastmcp import FastMCP
from armature_mcp_analytics import instrument_fastmcp

mcp = FastMCP("Customer MCP")

instrument_fastmcp(
    mcp,
    {
        "armature": {
            "api_key": os.getenv("ANALYTICS_INGEST_API_KEY"),
            "delivery": "await",
        }
    },
)

@mcp.tool
def lookup_customer(customer_id: str) -> dict:
    """Look up a customer by id."""
    return {"customer_id": customer_id, "status": "active"}

if __name__ == "__main__":
    mcp.run()

Agents see an optional telemetry object on each tool input schema. The SDK strips that object before your handler runs, then emits an authenticated batch to Armature.

Environment variables:

Variable Purpose
ANALYTICS_INGEST_API_KEY Armature ingest API key. Missing keys no-op for local development.
ANALYTICS_INGEST_URL Optional ingest endpoint override.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

armature_mcp_analytics-0.1.0.tar.gz (16.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

armature_mcp_analytics-0.1.0-py3-none-any.whl (15.4 kB view details)

Uploaded Python 3

File details

Details for the file armature_mcp_analytics-0.1.0.tar.gz.

File metadata

  • Download URL: armature_mcp_analytics-0.1.0.tar.gz
  • Upload date:
  • Size: 16.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for armature_mcp_analytics-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2ab10090c233c720478eaada32479582de0061c83ca6c293c71206aac2ddfd56
MD5 b5d18b5d62cf3ca7608c1001a403355c
BLAKE2b-256 ba2ebd7663c508293f1bbb9d5529d7774cf234f37c7856c4249fffb53db1137d

See more details on using hashes here.

Provenance

The following attestation bundles were made for armature_mcp_analytics-0.1.0.tar.gz:

Publisher: publish.yml on armature-tech/mcp-analytics-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file armature_mcp_analytics-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for armature_mcp_analytics-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 85bea3080420863e80e41317f0a79c4856a66a610f3f908d4094921dc9fd2b39
MD5 be818691923bc546593856278bee243d
BLAKE2b-256 fde37202faffb15c21c971dde1912c03d7482edca0a1fec3ee4a819241ef8336

See more details on using hashes here.

Provenance

The following attestation bundles were made for armature_mcp_analytics-0.1.0-py3-none-any.whl:

Publisher: publish.yml on armature-tech/mcp-analytics-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page