Skip to content

Conversation

Chethan-rao
Copy link
Contributor

@Chethan-rao Chethan-rao commented Apr 11, 2025

Type of Change

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

Description

This PR adds an api integration with open-router service.

  • decide-gateway
  • update-gateway-score

Additional Changes

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

Motivation and Context

How did you test it?

Create merchant_account, api_key, mca

  1. Enable SR for merchant
curl --location --request POST 'http://localhost:8080/account/merchant_1744368166/business_profile/pro_GrzjTHd5Pn5hAhwTZPRn/dynamic_routing/success_based/toggle?enable=dynamic_connector_selection' \
--header 'api-key: dev_a4XMpNXd3Yriz5DPsiwU6UbxEkiRkXdqHhwnJPolnVhssLaDEbOg6f5kE6B2hx1f'
  1. Enable Volume split
curl --location --request POST 'http://localhost:8080/account/merchant_1744368166/business_profile/pro_GrzjTHd5Pn5hAhwTZPRn/dynamic_routing/set_volume_split?split=100' \
--header 'api-key: dev_a4XMpNXd3Yriz5DPsiwU6UbxEkiRkXdqHhwnJPolnVhssLaDEbOg6f5kE6B2hx1f'
  1. Create a Payment
    Search for the log "Open router gateway_priority_map response"
image image

Checklist

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

@Chethan-rao Chethan-rao added the A-routing Area: Routing label Apr 11, 2025
@Chethan-rao Chethan-rao added this to the April 2025 Release milestone Apr 11, 2025
@Chethan-rao Chethan-rao requested review from a team as code owners April 11, 2025 09:33
Copy link

semanticdiff-com bot commented Apr 11, 2025

Review changes with  SemanticDiff

Changed Files
File Status
  crates/router/src/core/payments.rs  81% smaller
  crates/router/src/core/routing/helpers.rs  28% smaller
  crates/router/src/core/payments/routing.rs  6% smaller
  config/config.example.toml Unsupported file format
  config/development.toml Unsupported file format
  config/docker_compose.toml Unsupported file format
  crates/api_models/src/lib.rs  0% smaller
  crates/api_models/src/open_router.rs  0% smaller
  crates/router/src/configs/secrets_transformers.rs  0% smaller
  crates/router/src/configs/settings.rs  0% smaller
  crates/router/src/core/errors.rs  0% smaller
  crates/router/src/core/routing/transformers.rs  0% smaller

@Chethan-rao Chethan-rao force-pushed the open-router-integration branch from 7492b35 to 230d757 Compare April 11, 2025 09:38
@Chethan-rao Chethan-rao changed the title Open router integration refactor(dynamic_routing): add open router integration Apr 11, 2025
@Chethan-rao Chethan-rao linked an issue Apr 11, 2025 that may be closed by this pull request
@Chethan-rao Chethan-rao changed the title refactor(dynamic_routing): add open router integration feat(dynamic_routing): add open router integration Apr 11, 2025
@Chethan-rao Chethan-rao force-pushed the open-router-integration branch from 230d757 to a33d8a1 Compare April 11, 2025 09:45
@Chethan-rao Chethan-rao changed the title feat(dynamic_routing): add open router integration feat(dynamic_routing): add open router integration for success based routing Apr 12, 2025
jagan-jaya
jagan-jaya previously approved these changes Apr 16, 2025
Copy link
Contributor

@jagan-jaya jagan-jaya left a comment

Choose a reason for hiding this comment

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

LGTM added minor change

@Chethan-rao Chethan-rao dismissed stale reviews from jagan-jaya and prajjwalkumar17 via 93521db April 16, 2025 13:14
@Gnanasundari24 Gnanasundari24 added this pull request to the merge queue Apr 21, 2025
Merged via the queue into main with commit a51c9f0 Apr 21, 2025
28 of 32 checks passed
@Gnanasundari24 Gnanasundari24 deleted the open-router-integration branch April 21, 2025 14:32
pixincreate added a commit that referenced this pull request Apr 22, 2025
…acilitapay-pix-pmt

* 'main' of github.com:juspay/hyperswitch:
  fix(connector): revert noon-paypal (#7864)
  refactor(cypress): do not update `card_expiry` while updating card info (#7834)
  feat(vsaas): add processor_merchant_id and created_by column in payment_intents and payments_attempts for v1 (#7768)
  chore(dynamic-fields): remove billing details as required fields for Worldpay connector (#7853)
  feat(dynamic_routing): integration of elimination routing for core flows (#6816)
  chore(version): 2025.04.22.0
  revert: fix(connector): [noon] address `next_action_url` being `null` for cards in 3ds payment (#7859)
  feat(dynamic_routing): add open router integration for success based routing (#7795)
  feat(refunds_v2): Add refund create core flow (#7619)
  fix(core): [CARD TESTING GUARD] Added Card Testing Guard Config response in case of NULL (#7478)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-routing Area: Routing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

open router integration of success rate based routing
6 participants