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

refactor(core): Add 'redirect_response' field to CompleteAuthorizeData #1222

Merged
merged 9 commits into from
May 30, 2023

Conversation

srujanchikke
Copy link
Contributor

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

add redirect_response field to CompleteAuthorizeData instead of payload

Additional Changes

  • This PR modifies the API contract
  • This PR modifies the database schema
  • This PR modifies application configuration/environment variables

Motivation and Context

Previously we were sending only payload in CompleteAuthorizedData , for connector authorizedotnet query_params are required. In this PR redirect_response is added in CompleteAuthorizedData which contains both query_params and payload.

How did you test it?

Bluesnap goes through complete authorize flow for 3ds payment ,which uses payload in redirect response .So ,i have tested this connector in postman.
Screenshot 2023-05-21 at 7 44 05 PM
Screenshot 2023-05-21 at 7 44 22 PM

Check

list

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed submitted code
  • I added unit tests for my changes where possible
  • I added a CHANGELOG entry if applicable

@srujanchikke srujanchikke added A-core Area: Core flows C-refactor Category: Refactor R-waiting-on-L1 Review: Waiting on L1 reviewer labels May 21, 2023
@srujanchikke srujanchikke self-assigned this May 21, 2023
@srujanchikke srujanchikke requested review from a team as code owners May 21, 2023 15:30
@github-actions github-actions bot added the S-conventions-not-followed Status: This PR does not follow contributing guidelines label May 21, 2023
@srujanchikke srujanchikke changed the title refactor(core) : add redirect_response field to CompleteAuthorizeData refactor(core) : Add redirect_response field to CompleteAuthorizeData May 21, 2023
@srujanchikke srujanchikke changed the title refactor(core) : Add redirect_response field to CompleteAuthorizeData refactor(core): Add 'redirect_response' field to CompleteAuthorizeData May 21, 2023
@github-actions github-actions bot removed the S-conventions-not-followed Status: This PR does not follow contributing guidelines label May 21, 2023
@srujanchikke srujanchikke added the S-waiting-on-review Status: This PR has been implemented and needs to be reviewed label May 21, 2023

/// Allowed payment method types for a payment intent
#[schema(value_type = Option<Vec<PaymentMethodType>>)]
pub allowed_payment_method_types: Option<Vec<api_enums::PaymentMethodType>>,
}

#[derive(Default, Debug, Eq, PartialEq, serde::Deserialize, serde::Serialize, Clone, ToSchema)]
pub struct RedirectResponse {
pub param: Option<String>,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make this as secret.

pub browser_info: Option<BrowserInformation>,
pub connector_transaction_id: Option<String>,
pub connector_meta: Option<serde_json::Value>,
}

#[derive(Debug, Clone)]
pub struct CompleteAuthorizeRedirectResponse {
pub params: Option<String>,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

convert all fields as secret.

Signed-off-by: chikke srujan <[email protected]>
@srujanchikke srujanchikke requested review from a team and ashokkjag as code owners May 22, 2023 17:40
@srujanchikke srujanchikke requested a review from jarnura May 22, 2023 17:42
@jarnura jarnura removed the S-waiting-on-review Status: This PR has been implemented and needs to be reviewed label May 30, 2023
@jarnura jarnura added S-ready-for-merge and removed R-waiting-on-L1 Review: Waiting on L1 reviewer labels May 30, 2023
@jarnura jarnura added this pull request to the merge queue May 30, 2023
Merged via the queue into main with commit 77e60c8 May 30, 2023
@SanchithHegde SanchithHegde deleted the add_redirect_response_to_completeauthorize branch May 31, 2023 07:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-core Area: Core flows C-refactor Category: Refactor
Projects
No open projects
Status: Merged
Development

Successfully merging this pull request may close these issues.

3 participants