hyperswitch icon indicating copy to clipboard operation
hyperswitch copied to clipboard

refactor(connector): Use connector_request_reference_id for rapyd

Open vinfinity7 opened this issue 1 year ago • 8 comments

Type of Change

Fixes #2346

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

Description

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?

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
  • [ ] I added a CHANGELOG entry if applicable

vinfinity7 avatar Oct 29 '23 19:10 vinfinity7

@swangi-kumari @srujanchikke Kindly review this too !

vinfinity7 avatar Mar 16 '24 10:03 vinfinity7

Hi @vinfinity7 ,

The issue #2346 is not assigned to you, Please comment on the issue to get assigned it to you. And also changes done are not relevant. Please go through the issue once again and rapyd docs to find connector response reference id . We would be happy to help you if you have any queries on this issue.

srujanchikke avatar Mar 17 '24 05:03 srujanchikke

image update the field as given in the docs @srujanchikke

vinfinity7 avatar Mar 18 '24 06:03 vinfinity7

connector response reference id

Connector response reference id and connector request reference id are two different fields. Please go through the issue attached PR. This PR should be modifying response reference id not request reference id.

Please use following cargo commands -

cargo clippy --all-features ref - Cargo commands, and fix the errors thrown by clippy for the checks to pass .

srujanchikke avatar Mar 18 '24 07:03 srujanchikke

@srujanchikke can you be more clear as to exaclty where is the response data being handled image The last line has been added by me

vinfinity7 avatar Mar 18 '24 07:03 vinfinity7

@srujanchikke can you be more clear as to exaclty where is the response data being handled image The last line has been added by me

Yes, you're right. You need add it in ResponseData struct and map that to connector response reference id. Screenshot 2024-03-18 at 1 18 14 PM

srujanchikke avatar Mar 18 '24 07:03 srujanchikke

@srujanchikke image this shall work ?

vinfinity7 avatar Mar 18 '24 07:03 vinfinity7

@srujanchikke image this shall work ?

No this doesn't work, you are trying add field in transaction response, you need to map connector_response_reference_id to merchant_reference_id. which would be something like this

connector_response_reference_id: merchant_reference_id

and also you need to populate merchant_reference_id from connector response before mapping. Please go through this example PR for more info.

Please change the title of the PR to connector_response_reference_id for rapyd

srujanchikke avatar Mar 21 '24 03:03 srujanchikke