added pollbackpayment status

This commit is contained in:
Lincpay Tech
2025-12-03 17:29:10 +05:30
parent e4e1310325
commit 78c38e6d74
9 changed files with 168 additions and 10 deletions
@@ -0,0 +1,29 @@
package com.billpaymentservice.bbps.controller;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import com.billpaymentservice.bbps.dto.ResponseModel;
import com.billpaymentservice.bbps.dto.request.PaymentStartUserRequest;
import com.billpaymentservice.bbps.dto.request.PollBackRequest;
import com.billpaymentservice.bbps.service.PollBackService;
@RequestMapping("/payment")
public class PaymentPollBackController {
private final PollBackService pollBackService;
public PaymentPollBackController(PollBackService pollBackService) {
this.pollBackService = pollBackService;
}
@PostMapping(value = "/pollback", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
public ResponseEntity<ResponseModel> startIntentPayment(@Validated @RequestBody PollBackRequest pollBackRequest) {
ResponseModel response = pollBackService.managePollBack(pollBackRequest);
return ResponseEntity.ok(response);
}
}