Skip to content

Conversation

@saneroen
Copy link

Summary

This PR introduces Swagger-based Tool Loading, enabling the dynamic population of Agent tools from any external API by providing its Swagger/OpenAPI specification. This feature streamlines the process of extending Agent capabilities by automating endpoint discovery and tool configuration.

Key features include:

  • Swagger-based Tool Loading: Automatically parse and load tools from OpenAPI 3.0 or Swagger 2.0 specifications.
  • Dynamic Endpoint Selection: Users can choose specific API endpoints to expose as tools for their agents.
  • API Registry Management: A new interface and backend service to manage registered APIs and their associated tools.
  • Automated Schema Mapping: Converts API endpoint definitions into tool schemas for seamless agent integration.

Change Type

  • New feature (non-breaking change which adds functionality)

Testing

Tested the end-to-end flow of Swagger-based tool loading:

  1. Added a new API registry entry using a Swagger URL.
  2. Verified that endpoints were correctly discovered and displayed for selection.
  3. Selected endpoints and confirmed they were loaded as tools for the agent.
  4. Successfully executed agent queries that utilized the dynamically loaded tools.

Test Configuration:

  • Environment: Local development
  • Spec Formats: Swagger 2.0, OpenAPI 3.0.x

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have commented in any complex areas of my code
  • I have made pertinent documentation changes (Managed in librechat.ai repo)
  • My changes do not introduce new warnings
  • I have written tests demonstrating that my changes are effective or that my feature works
  • Local unit tests pass with my changes
  • Any changes dependent on mine have been merged and published in downstream modules.
  • A pull request for updating the documentation has been submitted.

@saneroen saneroen closed this Jan 30, 2026
@saneroen saneroen reopened this Jan 30, 2026
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