Skip to content
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

chore: transform request even for before request hooks failure #900

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

VisargD
Copy link
Collaborator

@VisargD VisargD commented Jan 28, 2025

Title:

  • transform request even for before request hooks failure

Description: (optional)

  • After the redaction guardrails went live, before_request_hooks now have the capability of updating request body. So the request body transform (OAI to provider format) was moved after the hook execution to use the hook-transformed request for the final provider request transformation. But if a hook fails with deny=true (446 response status code), then we are not transforming the request body to provider format. Its getting set as {} in the request options.
  • It does not affect any of the gateway functionalities but its better to keep the logic streamlined.

Related Issues: (optional)

@VisargD VisargD merged commit c4ffb3d into main Jan 28, 2025
2 checks passed
@VisargD VisargD deleted the chore/transform-req-for-request-hooks-deny-response branch January 28, 2025 18:44
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