Skip to main content

huaweicloud-mcp-core

Shared core library for all Huawei Cloud MCP servers in the huaweicloud-mcp monorepo.

Responsibilities

  • config — unified environment-variable configuration (McpSettings)
  • credentials — BasicCredentials / GlobalCredentials building with automatic project_id resolution via IAM (cached, overridable via HUAWEICLOUD_PROJECT_ID)
  • errors — McpToolError and wrap_sdk_error for the unified error envelope
  • security — ToolRisk (READ / WRITE / DANGEROUS) and the @guard decorator
  • guardrails — GuardrailsMiddleware (read-only mode, resource protection rules, output masking, structured JSONL audit); auto-installed by build_server()
  • output — paginated / single-object envelopes with token budget guards
  • server — build_server() / run_standard() bootstrap (stdio + streamable-http)

Usage

from huaweicloud_mcp_core.server import build_server, run_standard

mcp = build_server("myservice")

from myservice.tools import thing  # noqa: F401  (import registers tools)


def main() -> None:
    run_standard(mcp, service_name="myservice")

See docs/development/ in the repository root for the full specification.

Metadata

Release files for huaweicloud-mcp-core 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for huaweicloud-mcp-core 1.0.0
File Interpreter ABI Platform Actions
huaweicloud_mcp_core-1.0.0-py3-none-any.whl Python 3 none any Details for huaweicloud_mcp_core-1.0.0-py3-none-any.whl

Release files / huaweicloud_mcp_core-1.0.0-py3-none-any.whl

Download URL huaweicloud_mcp_core-1.0.0-py3-none-any.whl
Size 18.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
983f0d2055fdd87e9989d2af72a5e89478ade774be21c84a3e29693f9c56fef1
BLAKE2b-256 checksum
How to use checksums
3734d258cb01f789d02775c0b14c1b4a75084d4b811fdea4786b158270cd7d52
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Security for huaweicloud-mcp-core 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page