mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-11-01 19:42:27 +08:00
feat(response-log): add logging to the response (#1433)
This commit is contained in:
@ -604,6 +604,7 @@ where
|
||||
T: Debug,
|
||||
U: auth::AuthInfo,
|
||||
A: AppStateInfo,
|
||||
ApplicationResponse<Q>: Debug,
|
||||
CustomResult<ApplicationResponse<Q>, E>:
|
||||
ReportSwitchExt<ApplicationResponse<Q>, api_models::errors::types::ApiErrorResponse>,
|
||||
{
|
||||
@ -620,7 +621,10 @@ where
|
||||
&flow,
|
||||
)
|
||||
.await
|
||||
{
|
||||
.map(|response| {
|
||||
logger::info!(api_response =? response);
|
||||
response
|
||||
}) {
|
||||
Ok(ApplicationResponse::Json(response)) => match serde_json::to_string(&response) {
|
||||
Ok(res) => http_response_json(res),
|
||||
Err(_) => http_response_err(
|
||||
|
||||
Reference in New Issue
Block a user