Payment


GetPaymentOptions Method

Last Update Date: 21.10.2020
Method Adress /Api/AgencyService/GetPaymentOptions
Method Type POST
Token Required YES

Request Sample

{
   "transactionId": "aab69692-a73d-4e54-8f21-d22763fa3fb9"
}

Response Sample

{
   "header":{
      "requestId":"3cd82349-64ed-489a-bef5-b90fd66da387",
      "success":true,
      "messages":[
         {
            "id":10000000,
            "code":"OperationCompleted",
            "messageType":2,
            "message":"Operation was completed successfully"
         }
      ]
   },
   "body":{
      "options":[
         0,
         3,
         6
      ]
   }
}


GetPaymentOptionDetail Method

Last Update Date: 21.10.2020
Method Adress /Api/AgencyService/GetPaymentOptionDetail
Method Type POST
Token Required YES

Request Sample

{
  "transactionId":"aab69692-a73d-4e54-8f21-d22763fa3fb9",
   "PaymentOption":"3"
}

Response Sample

{
  "header": {
    "requestId": "37efbea7-a2bc-4e6a-939d-61eb12857946",
    "success": true,
    "messages": [
      {
        "id": 10000000,
        "code": "OperationCompleted",
        "messageType": 2,
        "message": "Operation was completed successfully"
      }
    ]
  },
  "body": {
    "detail": [
      {
        "options": [
          {
            "thumbnail": "/images/other/1/8/1/1009/akbank.jpg",
            "paymentTypes": [
              {
                "paymentCurrency": "EUR",
                "secure3D": true,
                "instalment": [
                  1
                ],
                "price": {
                  "amount": 828,
                  "currency": "EUR"
                },
                "pricebyBankCurrency": {
                  "amount": 3400.411,
                  "currency": "TRY"
                },
                "creditCardName": "VISA",
                "id": "1022",
                "name": "AKBANK EUR"
              }
            ],
            "id": "AKBANK",
            "name": "AKBANK"
          },
          {
            "thumbnail": "/images/other/1/8/1/1/finansbank.jpg",
            "paymentTypes": [
              {
                "paymentCurrency": "EUR",
                "secure3D": true,
                "instalment": [
                  1
                ],
                "price": {
                  "amount": 828,
                  "currency": "EUR"
                },
                "pricebyBankCurrency": {
                  "amount": 3400.411,
                  "currency": "TRY"
                },
                "creditCardName": "CARDFINANS",
                "id": "2",
                "name": "CREDIT CARD PAYMENT"
              },
              {
                "paymentCurrency": "EUR",
                "secure3D": true,
                "instalment": [
                  1,
                  2,
                  3
                ],
                "price": {
                  "amount": 828,
                  "currency": "EUR"
                },
                "pricebyBankCurrency": {
                  "amount": 3400.411,
                  "currency": "TRY"
                },
                "creditCardName": "CARDFINANS",
                "id": "4",
                "name": "CREDIT CARD PAYMENT 3 TAKSIT"
              }
            ],
            "id": "FINANS",
            "name": "FINANSBANK"
          },
          {
            "thumbnail": "/images/other/1/8/1/1014/garanti_bankasi.jpg",
            "paymentTypes": [
              {
                "paymentCurrency": "EUR",
                "secure3D": true,
                "instalment": [
                  1
                ],
                "price": {
                  "amount": 828,
                  "currency": "EUR"
                },
                "pricebyBankCurrency": {
                  "amount": 3400.411,
                  "currency": "TRY"
                },
                "creditCardName": "GARANTI CARD",
                "id": "1026",
                "name": "GARANTI EUR 1"
              }
            ],
            "id": "GARANTI_",
            "name": "GARANTI BANKASI"
          },
          {
            "thumbnail": "/images/other/1/8/1/1023/denizbank.jpg",
            "paymentTypes": [
              {
                "paymentCurrency": "EUR",
                "secure3D": true,
                "instalment": [
                  1
                ],
                "price": {
                  "amount": 828,
                  "currency": "EUR"
                },
                "pricebyBankCurrency": {
                  "amount": 3400.411,
                  "currency": "TRY"
                },
                "creditCardName": "DENIZBANKCARD",
                "id": "1033",
                "name": "DENIZBANK 1"
              }
            ],
            "id": "DENIZ",
            "name": "DENIZBANK"
          }
        ],
        "id": "3",
        "name": "Credit Card"
      }
    ]
  }
}

BeginPaymentTransaction Method

Last Update Date: 19.03.2021
Method Adress Api/PaymentService/BeginPaymentTransaction
Method Type POST
Token Required YES

Request Sample (PaymentOption:3)

{
   "TransactionId":"37efbea7-a2bc-4e6a-939d-61eb12857946",
   "PaymentOption":3,
   "PaymentTypeId":"1033",
   "Installment":1,
   "CardInfo":{
      "ExpiryMonth":"11",
      "ExpiryYear":"2021",
      "CardNo":"4090700102323514",
      "CardHolderFirstName":"AAA",
      "CardHolderLastName":"BBBB",
      "CvvNo":"834"
   },
   "SuccessUrl":"http://localhost:8080/secure3DSuccess.html",
   "ErrorUrl":"http://localhost:8080/secure3DError.html"
}

Response Sample (PaymentOption:3)

{
    "header": {
        "requestId": "eacfcec8-ccbe-4f04-9694-3dc97c219d33",
        "success": true,
        "messages": [
            {
                "id": 10000000,
                "code": "OperationCompleted",
                "messageType": 2,
                "message": "Operation was completed successfully"
            }
        ]
    },
    "body": {
        "html": "<input type=\"hidden\" name=\"Lang\" value=\"tr\" />\r\n<input type=\"hidden\" name=\"SecureType\" value=\"3DPay\" />\r\n<input type=\"hidden\" name=\"InstallmentCount\" value=\"\" />\r\n<input type=\"hidden\" name=\"TxnType\" value=\"PreAuth\" />\r\n<input type=\"hidden\" name=\"Hash\" value=\"fJZm4mU5nVl3e9i/zz5lCtP17IM=\" />\r\n<input type=\"hidden\" name=\"Rnd\" value=\"636411829726123772\" />\r\n<input type=\"hidden\" name=\"FailUrl\" value=\"http://192.168.2.191/TourVisio.WebService.Media/payment/DenizbankResponse\" />\r\n<input type=\"hidden\" name=\"Pan\" value=\"4090700102323514\" />\r\n<input type=\"hidden\" name=\"Cvv2\" value=\"834\" />\r\n<input type=\"hidden\" name=\"Expiry\" value=\"1121\" />\r\n<input type=\"hidden\" name=\"BonusAmount\" value=\"\" />\r\n<input type=\"hidden\" name=\"CardType\" value=\"0\" />\r\n<input type=\"hidden\" name=\"ShopCode\" value=\"3123\" />\r\n<input type=\"hidden\" name=\"PurchAmount\" value=\"225.87\" />\r\n<input type=\"hidden\" name=\"Currency\" value=\"949\" />\r\n<input type=\"hidden\" name=\"OrderId\" value=\"0a5650fbb60445b895854412bf1bee1f\" />\r\n<input type=\"hidden\" name=\"OkUrl\" value=\"http://192.168.2.191/TourVisio.WebService.Media/payment/DenizbankResponse\" />\r\n",
        "postUrl": "https://sanaltest.denizbank.com/MPI/Default.aspx",
        "paymentTransactionType": 2,
        "paymentTransactionId": "0a5650fbb60445b895854412bf1bee1f"
    }
}

Request Sample (PaymentOption:2)

{
  "currency": "EUR",
  "culture": "en-GB",
  "transactionId": "61962cb0-3505-49d9-811b-ef6e68d1ef02",
  "paymentOption": 2,
  "successUrl": "http://localhost:8080/PaymentResult/Success",
  "termsAndConditionsUrl": "http://localhost:8080/Content/RenderContent/TermsAndConditions",
  "errorUrl": "http://localhost:8080/PaymentResult/Error",
  "non3DPayment": false
}

Response Sample (PaymentOption:2)

{
  "header": {
    "requestId": "a3f2893f-bc84-47c8-9a31-c747d8ecbdb5",
    "success": true,
    "responseTime": "2021-03-17T11:51:55.5052693Z",
    "messages": [
      {
        "id": 10000000,
        "code": "OperationCompleted",
        "messageType": 2,
        "message": "Operation was completed successfully"
      }
    ]
  },
  "body": {
    "paymentTransactionType": 4,
    "paymentTransactionId": "1331501D210317N00004"
  }
}