You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 20 Next »

The enterprise can also find out the payment result (order status) by the order number using Web service. All possible order statuses are listed in the table "Order states".

To receive the payment result by order number, send a request to IPS Assist server via HTTP POST or SOAP method (in UTF-8 coding).

The request URL for receiving the order status:

https://<SERVER-NAME>/orderstate/orderstate.cfm.

The order search using Web service can be performed only for the specified time period. For this, you have to specify the time period, when the order payments started to be performed using the parameters STARTDAY, STARTMONTH, STARTYEAR setting forth the sampling starting date, and the parameters ENDDAY, ENDMONTH, ENDYEAR setting forth the sampling end date. If the parameters are not specified, or incorrectly specified, the default values will be applied. The default sampling end date is taken to be the current date, while the default sampling start date is the current date, minus three days.

List of request parameters:

Parameter

Mandatory field

Adopted values

Default value

Description

Ordernumber

Yes

String 128  characters


Order number

Merchant_ID

Yes

Number


The enterprise identifier in IPS Assist

Login

Yes

8-20 characters


Login (Latin letters, digits and symbol _)

Password

Yes

8-20 characters


Password (Latin letters and digits)

StartYear

No

Year in "2011" format

Minus three days from the current date

Sampling start date (GMT)

StartMonth

No

1-12

Minus three days from the current date

StartDay

No

1-31

Minus three days from the current date

StartHour

No

0-23

Minus three days from the current date

StartMin

No

0-59

Minus three days from the current date

EndYear

No

Year in "2011" format

Current year

Sampling end date (GMT)

EndMonth

No

1-12

Current month

EndDay

No

1-31

Current day

EndHour

No

0-23

Current hour

EndMin

No

0-59

Current minute

Format

No

1 – CSV
2 – WDDX
3 – XML
4 - SOAP

4

Format of the results output

An example of HTTP POST request for receiving a status of order 1001-01 whose payment started on April 1, 2011 (GMT):

<FORM ACTION="https://<SERVER-NAME>/orderstate/orderstate.cfm" METHOD="POST">
<INPUT TYPE="HIDDEN" NAME="Ordernumber" VALUE="1001-01">
<INPUT TYPE="HIDDEN" NAME="Merchant_ID" VALUE="Your Merchant_ID">
<INPUT TYPE="HIDDEN" NAME="Login" VALUE="Your login">
<INPUT TYPE="HIDDEN" NAME="Password" VALUE="Your password">
<INPUT TYPE="HIDDEN" NAME="Startyear" VALUE="2011">
<INPUT TYPE="HIDDEN" NAME="Startmonth" VALUE="04">
<INPUT TYPE="HIDDEN" NAME="Startday" VALUE="01">
<INPUT TYPE="HIDDEN" NAME="Starthour" VALUE="00">
<INPUT TYPE="HIDDEN" NAME="Startmin" VALUE="00">
<INPUT TYPE="HIDDEN" NAME="Endyear" VALUE="2011">
<INPUT TYPE="HIDDEN" NAME="Endmonth" VALUE="04">
<INPUT TYPE="HIDDEN" NAME="Endday" VALUE="02">
<INPUT TYPE="HIDDEN" NAME="Endhour" VALUE="00">
<INPUT TYPE="HIDDEN" NAME="Endmin" VALUE="00">
<INPUT TYPE="HIDDEN" NAME="Format" VALUE="3">
<INPUT TYPE="SUBMIT" NAME="Submit" VALUE="Submit">
</FORM>

List of response parameters:

Parameter

Value 

billnumber

Unique order number in IPS Assist

ordernumber

Order number

orderstate

Order status

orderamount

Original amount of order

ordercurrency

Original currency of order

packetdate

Request issue date (GMT)

checkvalue

MD5 from the string

An example of response result in CSV format:

ordernumber;billnumber;orderamount;ordercurrency;orderstate;packetdate;signature;checkvalue;2306-08;551508910014022;100.00;RUB;Approved;23.06.2011 11:59;; D6313123A5C09; 

In XML format:

<?xml version='1.0' encoding='utf-8' standalone='yes'?>
<!DOCTYPE result [
<!ATTLIST result
		  firstcode CDATA #REQUIRED
		  secondcode CDATA #REQUIRED
		  count CDATA #REQUIRED>
<!ELEMENT result (order*)>
<!ELEMENT order (ordernumber?,billnumber?,orderamount?,ordercurrency?,orderstate?,packetdate?,checkvalue?)>
<!ELEMENT ordernumber (#PCDATA)>
<!ELEMENT billnumber (#PCDATA)>
<!ELEMENT orderamount (#PCDATA)>
<!ELEMENT ordercurrency (#PCDATA)>
<!ELEMENT orderstate (#PCDATA)>
<!ELEMENT packetdate (#PCDATA)>
<!ELEMENT checkvalue (#PCDATA)>]> 
<result firstcode='0' secondcode='0' count='1'> 
<order> <ordernumber>0001-01</ordernumber> 
<billnumber>511111100000001</billnumber> 
<orderamount>100.00</orderamount>
<ordercurrency>RUB</ordercurrency> 
<orderstate>Approved</orderstate> 
<packetdate>01.01.2011 11:58</packetdate> 
<signature></signature> 
<checkvalue> </checkvalue> 
</order></result>

An example of request result in XML format, returning the error (wrong password):

<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<!DOCTYPE result [...]>
<result firstcode="7" secondcode="102" count="0"></result>