Authorization (pre-auth)

Pre-Authorize an amount on a credit/debit card


This request is to obtain an authorization for a specific amount for a proposed payment. An approved authorization indicates that the payment information is valid and that funds are available in the payers account. The authorization places the customer's balance on hold to ensure that you can Capture the funds.

Parameters

The following parameters are available to process an Authorization.

parameterdescriptionrequired
midthe Merchant ID (MID) assigned by QorCommerce or your merchant service provider (MSP)Yes
toptType Of Payment Transaction - set a value to simply tag and/or route a transaction to a pre-defined provider.No
reference_idA reference id that will be echo'd back in the message response.No
amountthe total amount to authorizeYes
service_chargethe amount of the total sum of this transaction that is made up of the service_chargeNo
creditcardthe credit card number -or- tokenYes
monththe card expiration monthYes
yearthe card expiration yearYes
cvvthe card verification valueYes
cardfullnamethe name printed or embossed on the front of the credit cardYes if store_card value is true
baddressthe card billing street addressNo
baddress2the card billing street 2 addressNo
bcitythe card billing city nameNo
bstatethe card billing state codeNo
bzipthe card billing zip codeYes
bcountrythe card billing country code
default: US
No
currencyThe currency to process. Defaults to USD if no value providedNo
invoiceidthe merchant invoice id associated with the saleNo
orderidunique merchant order tracking numberYes
ipaddressThe IP address of the client or server sending the requestNo
cfirstnamethe customer first nameNo
clastnamethe customer last nameNo
cemailthe customer email addressNo
cphonethe customer phone numberNo
risk_scorerisk score associated to this transaction (*if you are using a risk prevention system)No
store_cardif true will store card in QorCommerce Secure Vault and return a card tokenNo
metadataa set of key-value pairs that you can attach to a payment. This can be useful for storing additional information about the payment in a structured format.No
JSON Example

The following JSON example provides test values to process a manual card input sale. You can copy and paste these values in the Body Params section below to be used by the Try It feature

{
  "transaction_data": {
    "mid": "887728202",
    "amount": "1.5",
    "creditcard": "5544044490909090",
    "cvv": "123",
    "month": "04",
    "year": "19",
    "bzip": "92382",
    "cardfullname": "Crypto Kings LLC",
    "currency": "USD",
    "invoiceid": "INV-123332",
    "orderid": "193383",
    "ipaddress": "0.0.0.0",
    "baddress": "18312 All View Dr."
    "baddress2": "Apt 207",
    "bcity": "Running Springs",
    "bstate": "CA",
    "bcountry": "US",
    "cfirstname": "Russell",
    "clastname": "Hanneman",
    "cemail": "[email protected]",
    "cphone": "1-344-877-8928",
    "cwebaddress": "example.com",
    "store_card": 0
  }
}
JSON example - keyed/manual

The following JSON provides a template with empty values to process a manual card input sale. You can copy and paste these values in the Body Params section below to be used by the Try It feature

* values are required

{
  "transaction_data": {
    "mid": "",
    "amount": "*",
    "creditcard": "*",
    "cvv": "*",
    "month": "*",
    "year": "*",
    "bzip": "*",
    "cardfullname": "* if store_card = 1",
    "currency": "",
    "invoiceid": "",
    "orderid": "",
    "ipaddress": "",
    "baddress": ""
    "baddress2": "",
    "bcity": "",
    "bstate": "",
    "bcountry": "",
    "cfirstname": "",
    "clastname": "",
    "cemail": "",
    "cphone": "",
    "cwebaddress": "",
    "store_card": 0
  }
}

Hospitality Authorization (hotels and car rental)

The following additional parameters are available to process an Authorization for hotel and car rental agencies.

parameterdescriptionrequired
startDateThe beginning date for the stay or rental. string format as yymmdd. Example "190408"Yes
endDateThe ending date for the stay or rental. string format as yymmdd. Example "190416"Yes
durationan integer value representing a unit of time. For example 4 could represent hours, days or months. This value is used in combination with the rate parameter (below)Yes
ratethe decimal amount to charge for each time unit specified in the duration (above). For example, a rate of 34.99 represents $34.99 for one time unit in the durationYes
referenceNumFolio Number (Lodging) or Rental Agreement Number (Auto Rental)Yes
extraChargeuse an integer value to identify an additional charge item. Values are:
2= Restaurant
3= Gift Shop
4= Mini Bar
5= Telephone
6= Other
7= Laundry
No
flaguse an integer value to flag specific events. Values are:
1= Incremental Auth
2= No Show
3= Auth Reversal
No
initialAuthAmounta decimal amountNo
JSON Example

The following JSON example provides test values to process an authorization using the additional hospitality parameters. You can copy and paste these values in the Body Params section below to be used by the Try It feature

{
    "mid": "887728202",
    "amount": "1.5",
    "creditcard": "5544044490909090",
    "cvv": "123",
    "month": "04",
    "year": "19",
    "bzip": "92382",
    "cardfullname": "Crypto Kings LLC",
    "currency": "USD",
    "invoiceid": "INV-123332",
    "orderid": "193383",
    "ipaddress": "0.0.0.0",
    "baddress": "18312 All View Dr."
    "baddress2": "Apt 207",
    "bcity": "Running Springs",
    "bstate": "CA",
    "bcountry": "US",
    "cfirstname": "Russell",
    "clastname": "Hanneman",
    "cemail": "[email protected]",
    "cphone": "1-344-877-8928",
    "cwebaddress": "example.com",
    "store_card": 0,
    "startdate": "190408",
    "enddate": "190416",
    "duration": 9,
    "rate": 100.00,
    "refNumber": "2123342342121",
    "extraCharge": 3,
    "flag": 1,
    "initialAuthAmount": 1.5
}

Store Card Option

You can store the credit card information provided in the QorCommerce Secure Vault by setting the store_card parameter to true. The response will provide a token value representing the credit card that you can associate with your customer and/or a contract to use for payment in place of credit card data when needed.

JSON Example

The following JSON example provides test values to process a manual card input sale, store the card and return a card token. You can copy and replace these values in the Try It Out feature

{
    "mid": "887728202",
    "amount": "1.5",
    "creditcard": "5544044490909090",
    "cvv": "123",
    "month": "04",
    "year": "19",
    "bzip": "92838",
    "cardholdername": "Nelson Bighetti",
    "store_card": true,
}

Response Codes

Language
Click Try It! to start a request and see the response here!