SDK Integration: Clean MCP approach using decorators#50
Draft
AdvitXAtlan wants to merge 3 commits intomainfrom
Draft
SDK Integration: Clean MCP approach using decorators#50AdvitXAtlan wants to merge 3 commits intomainfrom
AdvitXAtlan wants to merge 3 commits intomainfrom
Conversation
inishchith
reviewed
Sep 16, 2025
Comment on lines
+57
to
+71
| print("Starting Atlan Giphy App") | ||
| print("FastAPI Server: http://localhost:8000") | ||
|
|
||
| if enable_mcp: | ||
| print("MCP Integration: ENABLED") | ||
| print(" • Activities with @mcp_tool will be auto-exposed") | ||
| print(" • MCP endpoint: http://localhost:8000/mcp") | ||
| print(" • Available tools: fetch_gif, send_email") | ||
| print(" • Debug with MCP Inspector using streamable HTTP") | ||
| print(" • For Claude Desktop: Use npx mcp-remote http://localhost:8000/mcp") | ||
| else: | ||
| print("MCP Integration: DISABLED") | ||
| print("To enable AI tools:") | ||
| print(" • ENABLE_MCP=true python main.py") | ||
| print(" • Or create .env file with: ENABLE_MCP=true") |
inishchith
reviewed
Sep 16, 2025
| readme = "README.md" | ||
| dependencies = [ | ||
| "atlan-application-sdk[workflows,tests]==0.1.1rc23", | ||
| "atlan-application-sdk[mcp,pandas,workflows]==0.1.1rc23", |
Contributor
There was a problem hiding this comment.
also the version bump depends on merging of the SDK PR atlanhq/application-sdk#698
inishchith
reviewed
Sep 16, 2025
| # for local development | ||
| [tool.uv.sources] | ||
| # atlan-application-sdk = { path = "../application-sdk", editable = true } | ||
| atlan-application-sdk = { path = "../../../application-sdk", editable = true } |
- Added @mcp_tool decorators to fetch_gif and send_email activities - Modified main.py to support both web and MCP modes via --mcp flag - Updated dependencies to use local SDK with MCP support - Added tests to verify decorator discovery works correctly - Uses enable_mcp parameter in BaseApplication for clean integration This demonstrates the final SDK-integrated approach where apps just: 1. Add @mcp_tool decorators to activities 2. Set enable_mcp=True in BaseApplication 3. Get automatic MCP server with zero manual MCP code
- Add @mcp_tool decorators to fetch_gif and send_email activities - Enable MCP via ENABLE_MCP environment variable - Remove command-line argument parsing for MCP - Update main.py to use BaseApplication enable_mcp flag - Clean up temporary test files and dependencies - Update README with comprehensive MCP documentation - Support Claude Desktop via npx mcp-remote integration Changes: - Activities now auto-exposed as AI tools when decorated - Single environment variable configuration (ENABLE_MCP=true) - Complete documentation for AI integration setup
150c28d to
cd9ebe1
Compare
📦 Trivy Vulnerability Scan Results
Report Summary
Scan Result Details✅ No vulnerabilities found during the scan for |
📦 Trivy Secret Scan Results
Report Summary
Scan Result Details✅ No secrets found during the scan for |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This demonstrates the final SDK-integrated approach where apps just:
Changelog
Additional context (e.g. screenshots, logs, links)
Checklist