Exemplo n.º 1
0
 public TransactionInitializeResponse Initialize(TransactionInitializeRequest request, bool makeReferenceUnique = false)
 {
     if (makeReferenceUnique && request.Reference != null)
     {
         request.Reference = $"{request.Reference}-{Guid.NewGuid().ToString().Substring(0, 8)}";
     }
     return(_api.Post <TransactionInitializeResponse, TransactionInitializeRequest>("transaction/initialize", request));
 }
Exemplo n.º 2
0
 public ChargeResponse ChargeAuthorizationCode(AuthorizationCodeChargeRequest request, bool makeReferenceUnique = false)
 {
     if (makeReferenceUnique && request.Reference != null)
     {
         request.Reference = $"{request.Reference}-{Guid.NewGuid().ToString().Substring(0, 8)}";
     }
     return(_api.Post <ChargeResponse, AuthorizationCodeChargeRequest>("charge", request));
 }
Exemplo n.º 3
0
 public ChargeResponse ChargeAuthorizationCode(AuthorizationCodeChargeRequest request) =>
 _api.Post <ChargeResponse, AuthorizationCodeChargeRequest>("charge", request);
Exemplo n.º 4
0
 public TransferOtpResponse ResendOtp(string transferCode, ResendOtpReasons reason) => _api.Post <TransferOtpResponse, dynamic>("transfer/resend_otp", new
 {
     transfer_code = transferCode,
     reason        = reason == ResendOtpReasons.ResendOtp ? "resend_otp" : "transfer"
 });