-
Notifications
You must be signed in to change notification settings - Fork 395
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Backend: include required headers in swagger #935
Backend: include required headers in swagger #935
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #935 +/- ##
==========================================
- Coverage 79.77% 79.76% -0.01%
==========================================
Files 295 295
Lines 11965 11951 -14
==========================================
- Hits 9545 9533 -12
+ Misses 2420 2418 -2 ☔ View full report in Codecov by Sentry. |
… with path, query, and header values
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me—just one small question to confirm
Adjusted the injectable dependencies to specify the headers expected.
Had to change organization_id as a query parameter because it was conflicting with organization-id header in the generated client. This had no effect on frontend, because organization_id query parameter is not used.
Also took care of TODO for having auth on only some endpoints in the user router.
AI Description
This PR introduces a new
DependencyType
class to thesrc/backend/config/routers.py
file, which is used to define the dependencies for each router. TheRouterName
class is also updated to include a newDependencyType
attribute.The
src/backend/main.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/routers/agent.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/routers/organization.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/routers/user.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/services/auth/request_validators.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/services/auth/utils.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/services/request_validators.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/integration/routers/test_agent.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/integration/routers/test_conversation.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/unit/routers/auth/test_authorization_header.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/unit/routers/test_chat.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/unit/routers/test_conversation.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/backend/tests/unit/services/auth/test_request_validators.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/interfaces/assistants_web/src/cohere-client/generated/services.gen.ts
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/interfaces/coral_web/src/cohere-client/generated/services.gen.ts
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/interfaces/coral_web/src/cohere-client/generated/types.gen.ts
file is updated to import the newDependencyType
class and use it to set the router dependencies.The
src/interfaces/assistants_web/src/components/UI/Slider.tsx
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/config/routers.py
file is updated to include a newDependencyType
class, which is used to define the dependencies for each router. TheRouterName
class is also updated to include a newDependencyType
attribute.src/backend/main.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/routers/agent.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/routers/organization.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/routers/user.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/services/auth/request_validators.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/services/auth/utils.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.src/backend/services/request_validators.py
file is updated to import the newDependencyType
class and use it to set the router dependencies.