Skip to content

Adopt the console Python SDK for control-plane tools - #91

Merged
ChiragAgg5k merged 1 commit into
mainfrom
feat/console-python-sdk
Aug 3, 2026
Merged

Adopt the console Python SDK for control-plane tools#91
ChiragAgg5k merged 1 commit into
mainfrom
feat/console-python-sdk

Conversation

@ChiragAgg5k

Copy link
Copy Markdown
Member

Summary

  • Replace the server-side appwrite dependency with the published appwrite-console 0.2.1 SDK.
  • Expose the complete console control-plane catalog to hosted OAuth sessions: 38 services and 981 hidden tools.
  • Preserve a reviewed API-key stdio surface: 26 services and 647 project-key-compatible tools, including DocumentsDB, VectorsDB, and text embeddings.
  • Add console, organization, and project target metadata to catalog/search results and validate required hosted target IDs before execution.
  • Hide the SDK-internal model_type parameter from generated MCP schemas.

Catalog policy

The authentication boundary lives in catalog_policy.py:

  • Hosted OAuth automatically receives every service shipped by the console SDK.
  • API-key stdio is allowlisted, so newly generated console services cannot leak into local project-key deployments without review.
  • Console-only additions to existing SDK services and administration-only DocumentsDB/VectorsDB operations are explicitly excluded from stdio.

The public MCP surface remains unchanged at up to four operator tools.

Live verification

The new OAuth integration suite exercises one safe read through the MCP registration/execution path for every non-billable added service. Against staging, all 14 probes passed, including regions, organizations, domains, projects, notifications, DocumentsDB, migrations, dedicated databases, usage, VCS, VectorsDB, and WAF.

Text embeddings are available in both applicable catalogs, but their live probe requires APPWRITE_TEST_BILLABLE_EMBEDDINGS=1 to avoid unexpected charges.

Test plan

  • uv run --group dev ruff check src tests
  • uv run --group dev black --check src tests
  • uv run --group dev pyright
  • uv run python -m unittest discover -s tests/unit -v (200 tests)
  • Build the source distribution and wheel with uv build
  • Run the read-only OAuth integration suite against live staging (14 service probes)
  • docker build -t appwrite-mcp:ci . (local Docker/OrbStack daemon unavailable; CI will run this)

@greptile-apps

greptile-apps Bot commented Aug 3, 2026

Copy link
Copy Markdown

Greptile Summary

The PR replaces the server SDK with appwrite-console and introduces authentication-aware catalog construction.

  • Adds an allowlisted API-key profile while exposing the complete console SDK catalog to hosted OAuth sessions.
  • Adds project, organization, and console target metadata and validates required hosted target IDs.
  • Updates SDK imports, generated schemas, documentation, and integration/unit coverage for the expanded catalog.

Confidence Score: 5/5

The PR appears safe to merge, with no concrete changed-code defect identified.

The catalog filtering, target-context enforcement, SDK migration, and transport-specific registration paths are internally consistent, and no reachable failure remained after reviewing their call flows and coverage.

Important Files Changed

Filename Overview
src/mcp_server_appwrite/catalog_policy.py Defines centralized OAuth/API-key catalog filtering and service-level target-context metadata.
src/mcp_server_appwrite/server.py Migrates SDK integration, applies catalog profiles, configures target-aware clients, and registers the appropriate service surface per transport.
src/mcp_server_appwrite/operator.py Surfaces target context in catalog results and validates required project or organization IDs before hosted execution.
src/mcp_server_appwrite/service.py Filters generated service methods, propagates context metadata, and hides SDK-internal parameters from MCP schemas.
tests/integration/test_console_sdk_oauth.py Adds opt-in live OAuth probes covering the newly exposed console and project services.
pyproject.toml Replaces the server-side Appwrite SDK dependency with the console SDK release line.

Reviews (1): Last reviewed commit: "(feat): adopt console Python SDK" | Re-trigger Greptile

@ChiragAgg5k
ChiragAgg5k merged commit 9c3bd0c into main Aug 3, 2026
5 checks passed
@ChiragAgg5k
ChiragAgg5k deleted the feat/console-python-sdk branch August 3, 2026 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant