You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: Add auth_tools support and fix test infrastructure (#66)
* Add auth_tools field for selective authentication in OpenAPI tool generation
- Add auth_tools field to HttpCallTemplate for tool-specific authentication
- Implement compatibility checking between OpenAPI security schemes and auth_tools
- Apply real credentials when compatible, use placeholders when incompatible
- Preserve existing behavior for public endpoints (no auth required)
- Add comprehensive test coverage for all authentication scenarios
- Update documentation with auth_tools examples and usage
- Maintain full backward compatibility
* Update implementation files and documentation for auth_tools feature
- Update HttpCallTemplate, HttpCommunicationProtocol, and OpenApiConverter
- Add auth_tools examples to README.md
- Update existing tests for new auth_tools parameter
- Add integration test for auth_tools field functionality
* fix: resolve pytest fixture dependency issue in HTTP tests
- Fix aiohttp_client fixture usage by properly injecting app dependency
- Ensure all test fixtures receive required parameters correctly
- All 153 tests now pass without fixture conflicts
* feat: add auth_tools support to text plugin
- Add auth_tools field to TextCallTemplate for OpenAPI-generated tools
- Pass auth_tools to OpenApiConverter when processing local OpenAPI specs
- Update documentation to reflect new authentication capabilities
- Add test coverage for auth_tools functionality
- Maintains backward compatibility (auth_tools is optional)
This allows text plugin to apply authentication to tools generated from
local OpenAPI specifications, enabling secure API calls while keeping
file access authentication-free.
* fix: add proper serialization/validation for auth and auth_tools fields
- Add field_serializer and field_validator for auth_tools in TextCallTemplate
- Add field_serializer and field_validator for both auth and auth_tools in HttpCallTemplate
- Use AuthSerializer.validate_dict() for proper dict-to-Auth conversion
- Add comprehensive test coverage for auth_tools serialization
- Ensures dict configurations preserve all critical authentication fields
- All 155 tests pass with proper field validation
* Update README.md
---------
Co-authored-by: Razvan Radulescu <[email protected]>
"auth_tools": { // Optional, authentication for converted tools, if this call template points to an openapi spec that should be automatically converted to a utcp manual (applied only to endpoints requiring auth per OpenAPI spec)
auth_tools: Optional[Auth] =Field(default=None, description="Authentication configuration for generated tools (applied only to endpoints requiring auth per OpenAPI spec)")
99
107
headers: Optional[Dict[str, str]] =None
100
108
body_field: Optional[str] =Field(default="body", description="The name of the single input field to be sent as the request body.")
101
109
header_fields: Optional[List[str]] =Field(default=None, description="List of input fields to be sent as request headers.")
0 commit comments