feat: add manifest_url to get_connector_info tool#742
Conversation
- Add manifest_url field to ConnectorInfo class - Update get_connector_info function to populate manifest URL - Use same URL pattern as connector-builder-mcp: https://connectors.airbyte.com/metadata/airbyte/{connector_name}/latest/metadata.yaml Co-Authored-By: AJ Steers <aj@airbyte.io>
Original prompt from AJ Steers |
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
👋 Greetings, Airbyte Team Member!Here are some helpful tips and reminders for your convenience. Testing This PyAirbyte VersionYou can test this version of PyAirbyte using the following: # Run PyAirbyte CLI from this branch:
uvx --from 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1754440011-add-manifest-url-to-connector-info' pyairbyte --help
# Install PyAirbyte from this branch for development:
pip install 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1754440011-add-manifest-url-to-connector-info'Helpful ResourcesPR Slash CommandsAirbyte Maintainers can execute the following slash commands on your PR:
Community SupportQuestions? Join the #pyairbyte channel in our Slack workspace. |
There was a problem hiding this comment.
Pull Request Overview
This PR adds a manifest_url field to the ConnectorInfo class, enabling MCP clients to directly access connector manifest URLs without requiring separate API calls. The implementation constructs URLs using the established Airbyte connectors API pattern.
Key Changes:
- Added
manifest_urlfield toConnectorInfoclass as an optional string - Updated
get_connector_infofunction to populate manifest URLs using the standardized Airbyte API pattern - Maintains backward compatibility with existing
ConnectorInfousage
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. 📝 WalkthroughWalkthroughA new optional Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Possibly related PRs
Suggested reviewers
Would you like to consider adding a test to verify that the 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (2)
airbyte/mcp/_connector_registry.py (2)
92-92: Add aFielddescription for the new attribute?All the other optional attributes in
ConnectorInfoeither have a self-explanatory name or are documented via their own types. For consistency and to help downstream users (e.g., in autogenerated docs), would you consider annotatingmanifest_urlwith a shortField(description="…")like the other parameters? wdyt?
121-124: Consider extracting the URL template (and quoting the connector name) into a constant/helper?Hard-coding the string literal here works, but:
- Re-using the same pattern elsewhere would require duplication.
- Some connector names may contain characters that need URL encoding (unlikely but possible).
Would it be cleaner to define something like
_MANIFEST_URL_TPL = ( "https://connectors.airbyte.com/metadata/airbyte/{connector}/latest/metadata.yaml" ) manifest_url = _MANIFEST_URL_TPL.format(connector=quote(connector_name, safe=""))at the top of the file (or in a small helper), using
urllib.parse.quotefor safety? This keeps the function body slimmer and the template centralised. Wdyt?
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
airbyte/mcp/_connector_registry.py(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
- GitHub Check: Pytest (All, Python 3.11, Ubuntu)
- GitHub Check: Pytest (All, Python 3.11, Windows)
- GitHub Check: Pytest (No Creds)
- GitHub Check: Pytest (All, Python 3.10, Windows)
- GitHub Check: Pytest (All, Python 3.10, Ubuntu)
- GitHub Check: Pytest (Fast)
🔇 Additional comments (1)
airbyte/mcp/_connector_registry.py (1)
130-130: Returnmanifest_urlonly when construction succeeded?If, for any reason, the earlier string interpolation fails (e.g., an unexpected character that raises in future validation logic), returning
Nonekeeps the contract of “optional.” Do you want to wrap the assignment in atry/exceptand fall back toNoneto be extra defensive, or is the current always-present string acceptable? Wdyt?
…ing new one Addresses feedback from @aaronsteers to reuse existing constants rather than creating duplicates. Co-Authored-By: AJ Steers <aj@airbyte.io>
feat: add manifest_url to get_connector_info tool
Summary
This PR adds a
manifest_urlfield to theConnectorInfoclass returned by theget_connector_infoMCP tool. This allows MCP clients to directly access the connector manifest URL without needing to make a separate call to theget_connector_manifesttool from connector-builder-mcp.Key Changes:
manifest_url: str | None = Nonefield toConnectorInfoclassget_connector_infofunction to populate the manifest URL using the pattern:https://connectors.airbyte.com/metadata/airbyte/{connector_name}/latest/metadata.yamlThis complements the recently added
get_connector_manifestcommand in connector-builder-mcp, providing users with direct access to manifest URLs when they already have connector info.Review & Testing Checklist for Human
source-faker,destination-duckdb) to ensure the endpoint returns valid YAML contentget_connector_infoand verify themanifest_urlfield is properly populated and accessibleDiagram
%%{ init : { "theme" : "default" }}%% graph TB MCPClient["MCP Client"] GetConnectorInfo["get_connector_info()"] ConnectorInfo["ConnectorInfo Class"] ManifestURL["manifest_url field"] AirbyteAPI["connectors.airbyte.com"] MCPClient --> GetConnectorInfo GetConnectorInfo --> ConnectorInfo ConnectorInfo --> ManifestURL ManifestURL -.-> AirbyteAPI ConnectorInfo:::major-edit ManifestURL:::major-edit GetConnectorInfo:::minor-edit MCPClient:::context AirbyteAPI:::context subgraph Legend L1[Major Edit]:::major-edit L2[Minor Edit]:::minor-edit L3[Context/No Edit]:::context end classDef major-edit fill:#90EE90 classDef minor-edit fill:#87CEEB classDef context fill:#FFFFFFNotes
ConnectorInfousage will continue to work unchangedRequested by: AJ Steers (Aaron ("AJ") Steers (@aaronsteers))
Devin Session: https://app.devin.ai/sessions/050f37720b8f485a86ad1fbe51d5e013
Summary by CodeRabbit
Important
Auto-merge enabled.
This PR is set to merge automatically when all requirements are met.