Credentials: Custom Provider Input #166#177
Closed
priyanshu6238 wants to merge 11 commits intoProjectTech4DevAI:mainfrom
Closed
Credentials: Custom Provider Input #166#177priyanshu6238 wants to merge 11 commits intoProjectTech4DevAI:mainfrom
priyanshu6238 wants to merge 11 commits intoProjectTech4DevAI:mainfrom
Conversation
…pecific credentials - Introduced a new column 'provider' in the credential table to support multiple credential providers. - Updated API routes to handle provider-specific credential operations, including creation, retrieval, updating, and deletion. - Enhanced validation for provider credentials and added support for multiple providers in the data model. - Refactored existing credential handling functions to accommodate the new structure and improve error handling. - Ensured backward compatibility by maintaining existing functionality while expanding capabilities.
…reation, enhance readability, and ensure proper handling of provider-specific data.
…roper checks for credential existence; update tests for accuracy in response validation.
… and improved error responses; update tests for accurate status codes and messages.
…redential fields; improve error responses for organization checks and unexpected exceptions.
Codecov ReportAttention: Patch coverage is
📢 Thoughts on this report? Let us know! |
c512bac to
35329e2
Compare
Closed
Collaborator
|
cherry picked it here |
Closed
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.
Current State
Key Changes
Multi-provider support:
Enabled storing credentials for multiple providers (e.g., OpenAI, Gemini) per organization.
Flexible credential structure:
Refactored data model to handle provider-specific credential fields dynamically.
Soft deletion logic:
Credentials are marked as inactive instead of being permanently deleted, allowing safer recovery.
Isolated provider updates:
Updates apply only to the specified provider without overwriting other credentials.
Improved error handling:
Clear and appropriate HTTP status codes are used (400, 404, 500) to aid client-side debugging.
Provider verification:
Ensured that only supported providers can be added or updated using validate_provider().
Ran
fastapi run --reload app/main.pyordocker compose upin the repository root and test.If you've fixed a bug or added code that is tested and has test cases.