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
Credentials: Add support for org credentials (#179)
* Add provider column to credential table and update API for provider-specific 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.
* Refactor credential tests to streamline organization and credential creation, enhance readability, and ensure proper handling of provider-specific data.
* Add soft delete functionality for credentials and update tests to verify deletion
* Refactor credential handling to improve error management and ensure proper checks for credential existence; update tests for accuracy in response validation.
* Enhance credential update handling with organization existence checks and improved error responses; update tests for accurate status codes and messages.
* Enhance credential update handling with validation for provider and credential fields; improve error responses for organization checks and unexpected exceptions.
* Refactor credential
* Fix down_revision reference in migration script for provider column addition
* added provider test in core
* refactor test_provider.py
* updates
* cherry picking from other PR
* using encrypt/decrypt
* cleanups
* decrypting credentials
* added support for per project per organization
* few more steps forward to per org per project per provider
* encrypting the entire credentials column
* added testcases
* updating threads codes
* updating time
* updating time
* reverting changes
* update migration
* updated testcases
* updated credentials testcases
* using langfuse from creds
* few cleanups
* cleanup & refactoring
* refactor security
* getting rid of redundant str()
* using now()
* cleanup few testcases and code
---------
Co-authored-by: Priyanshu singh <111607560+PriyanSingh@users.noreply.github.com>
Co-authored-by: Akhilesh Negi <akhileshnegi@Akhileshs-MacBook-Pro.local>
summary="Create new credentials for an organization and project",
29
+
description="Creates new credentials for a specific organization and project combination. This endpoint requires superuser privileges. Each organization can have different credentials for different providers and projects. Only one credential per provider is allowed per organization-project combination.",
summary="Get all credentials for an organization and project",
81
+
description="Retrieves all provider credentials associated with a specific organization and project combination. If project_id is not provided, returns credentials for the organization level. This endpoint requires superuser privileges.",
summary="Get specific provider credentials for an organization and project",
95
+
description="Retrieves credentials for a specific provider (e.g., 'openai', 'anthropic') for a given organization and project combination. If project_id is not provided, returns organization-level credentials. This endpoint requires superuser privileges.",
summary="Update organization and project credentials",
117
+
description="Updates credentials for a specific organization and project combination. Can update specific provider credentials or add new providers. If project_id is provided in the update, credentials will be moved to that project. This endpoint requires superuser privileges.",
summary="Delete specific provider credentials for an organization and project",
158
+
description="Removes credentials for a specific provider while keeping other provider credentials intact. If project_id is provided, only removes credentials for that project. This endpoint requires superuser privileges.",
summary="Delete all credentials for an organization and project",
191
+
description="Removes all credentials for a specific organization and project combination. If project_id is provided, only removes credentials for that project. This is a soft delete operation that marks credentials as inactive. This endpoint requires superuser privileges.",
0 commit comments