Status Transaction

This API method is used by the merchant in order to re-check for an already processed (or initialized) transaction in the Payment System. This method would return the latest and correct transaction status and can be called at all times by the merchant.

Also, there are some Acquirers or Banks Systems that do not complete instantly the process, or sometimes have connectivity issues sending back a failed response or timing-out, but offer a status check service for the transaction. In this case, the transaction status query API (also available as a function in the Backoffice) is able to retrieve the final state of the transaction from the Bank/Acquirer system, update accordingly the state in the Payment Platform and notify the merchant.

To implement this method:

  1. The merchant initiates a HTTPS POST method to the Intrapay endpoint URL with all the necessary information as url-encoded key-value pairs;
    URL: payment.intrapay.com/transaction/status
  2. The system will respond to the Merchant with the result of the transaction(latest status);
  3. The Merchant performs updates in his system and may notify the customer.

Status Transaction Fields

Order (pSign)Field NameDetailsMinMaxTypeRequired
01merchantIDMerchant id supplied by Intrapay18NumberYes
02transactionIDIntrapay transaction ID150StringYes*
03orderIDThe unique Merchant Order ID164StringYes*
04pSignThe SHA signature used to secure protocol4040StringYes

*   Atleast one should be sent.


Example Status Request:

[POST URL] https://payment.intrapay.com/transaction/status

[POST PARAMS]

<?php
    	
require_once("classes/Api.php");
    	
$endPointUrl = "https://payment.intrapay.com/transaction/status";	// api name to be process
$passCode = "PASSCODE_GOES_HERE"; //your pass Code

$postData["merchantID"] = "MERCHANT_ID_GOES_HERE"; //your merchant ID
$postData["transactionID"] = "TRANSACTION_ID_GOES_HERE"; //transaction ID
$postData["orderID"] = rand (100000,999999); //unique order ID

try {
	$api = new Api();
   
	$data = $api->generatePsign( $passCode, $postData );
   
	echo $api->apiCurlRequest( $data , $endPointUrl);
   
} catch (Exception $e) {
	echo "Caught exception: ",  $e->getMessage(), "\n";
}
   
?>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8" %>
<%@ page import="java.net.*, java.util.*, com.intrapay.util.*" %>
<%
	String endPointUrl = "https://payment.intrapay.com/transaction/status";
	String passCode = "PASSCODE_GOES_HERE"; //your pass Code
	String merchantID = "MERCHANT_ID_GOES_HERE"; //your merchant ID
	String transactionID = "TRANSACTION_ID_GOES_HERE"; //transaction ID
	String orderID = new Random().nextInt(999999) + ""; // unique order ID

	String pSign = PSignUtil.generatePSign(passCode + merchantID + transactionID + orderID);

	String and = "&";
	StringBuffer requestData = new StringBuffer();

	requestData.append("merchantID=" + merchantID);
	requestData.append(and + "transactionID=" + transactionID);
	requestData.append(and + "orderID=" + orderID);
	requestData.append(and + "pSign=" + pSign);

	String result = ServerPost.post(requestData.toString(), endPointUrl);
%>
<%=result%>
var request = require('request');
var querystring = require('querystring');

/*
 * 
 * Merchant's Data Variables.
 * 
 */
var postUrl = 'https://payment.intrapay.com/transaction/status'; //api name to be process
var passCode = 'PASSCODE_GOES_HERE'; //your pass Code
var merchantID = 'MERCHANT_ID_GOES_HERE'; //your merchant ID
var transactionID = 'TRANSACTION_ID_GOES_HERE'; //transaction ID
var orderID = Date.now(); // unique order ID

/*
*
* Generate pSign
*
*/
var crypto = require('crypto'), shasum = crypto.createHash('sha1');

shasum.update(passCode + merchantID + transactionID + orderID);
var pSign = shasum.digest('hex');

/*
*
* Ready HTTP Post with url-encoded data
*
*/

var data = {
		'passCode' : passCode,
		'merchantID' : merchantID,
		'transactionID' : transactionID,
		'orderID' : orderID,
};

var formData = querystring.stringify(data);
var contentLength = formData.length;
var headers = {
    "Content-Length" : contentLength,
    "Content-Type" : "application/x-www-form-urlencoded",
}

var options = {
    url : postUrl,
    method : "POST",
    headers : headers,
    body : formData,
}

request(options, function(err, res, body) {
    if (res && (res.statusCode === 200 || res.statusCode === 201)) {
        // return result
        console.log(body);
    }
});
require 'time'
require_relative 'classes/API'

api = API.new

postUrl = 'https://payment.intrapay.com/transaction/status' #api name to be process
passCode = 'PASSCODE_GOES_HERE' #your pass Code
merchantID = 'MERCHANT_ID_GOES_HERE' #your merchant ID
transactionID = 'TRANSACTION_ID_GOES_HERE' //transaction ID
orderID = Time.now.to_i #unique order ID

postData = Hash[
	'merchantID' => merchantID,
	'transactionID' => transactionID,
	'orderID' => orderID
]

postData['pSign'] = api.generatePsign(passCode, postData)

puts api.apiPostRequest(postData, postUrl)
<%@ Page Language="C#" %>
<%@ Import Namespace="Intrapay.Api.Util" %> 
<%
	String endPointUrl = "https://payment.intrapay.com/transaction/status";
	String passCode = "PASSCODE_GOES_HERE"; //your pass Code
	String merchantID = "MERCHANT_ID_GOES_HERE"; //your merchant ID
	String transactionID = "TRANSACTION_ID_GOES_HERE"; //transaction ID
	String orderID = new Random().Next(1, 999999).ToString(); //unique order ID

	String pSign = PSignUtil.GeneratePSign(passCode + merchantID + transactionID + orderID);
	String and = "&";
	StringBuilder requestData = new StringBuilder();

	requestData.Append("merchantID=" + merchantID);
	requestData.Append(and + "transactionID=" + transactionID);
	requestData.Append(and + "orderID=" + orderID);
	requestData.Append(and + "pSign=" + pSign);

	String result = ServerPost.Post(requestData.ToString(), endPointUrl);
	Response.Write(result);
%>
from classes.API import API

import time

postUrl = 'https://payment.intrapay.com/transaction/status' #api name to be process
passCode = 'PASSCODE_GOES_HERE' //your pass Code
merchantID = 'MERCHANT_ID_GOES_HERE' //your merchant ID
transactionID = 'TRANSACTION_ID_GOES_HERE' //transaction ID
orderID = time.time() #unique order ID

postData = {
	'passCode' => passCode,
	'merchantID' => merchantID,
	'transactionID' => transactionID,
	'orderID' => orderID
}

postData['pSign'] = API.generatePsign(passCode, postData)
print(API.apiPostRequest(postData, postUrl))

You will see the response here...