Charge a user’s account
The doCharge
operation charges a user’s account based on the supplied parameters.
When extra parameters are supplied, charging is determined by the client system. However, when no extra parameters are supplied, charging is determined by the Content Retail Service. |
doCharge + SOAP XML request
content-type: application/SOAP+XML
SOAP XML request
This example shows the doCharge
request with the mandatory extra parameters supplied.
See the doCharge parameter descriptions for more details. |
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchemainstance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:ws="http://ws.srs.sm.com">
<soapenv:Header />
<soapenv:Body>
<ws:doCharge soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<providerId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">6010
</providerId>
<applicationId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">50000029
</applicationId>
<serviceId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">30000020
</serviceId>
<originId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">9
</originId>
<operationId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">JG
</operationId>
<msisdn xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">5536608410
</msisdn>
<contentId xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">001
</contentId>
<contentDescription xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">PortalSRS
</contentDescription>
<extra-params xsi:type="soapenc:string"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
<param>
<name>totalPrice</name>
<value>12</value>
</param>
<param >
<name>retailPrice</name>
<value>11</value>
</param>
<param >
<name>calculatedTax</name>
<value>0</value>
</param>
<param >
<name>region</name>
<value>1</value>
</param>
<param >
<name>profile</name>
<value>0</value>
</param>
</extra-params>
</ws:doCharge>
</soapenv:Body>
</soapenv:Envelope>
doCharge parameter descriptions
These are the SOAP XML parameters for the doCharge
request.
doCharge mandatory parameters
parameter | type | description | ||
---|---|---|---|---|
|
string |
Identifies the billing content provider. |
||
|
string |
Identifies the application submitting the transaction.
|
||
|
string |
The product identifier.
|
||
|
string |
Unique ID of the merchant submitting the transaction.
|
||
|
string |
The client system transaction ID.
|
||
|
string |
The end user’s MSISDN; this is the subscriber’s number that is charged for the current transaction. |
||
|
string |
The content ID of the content purchased. This is assigned by the client system. |
||
|
string |
The name of the content. This is assigned by the client system.
|
||
|
string |
Tag value set of data to be passed by the client system.
|
doCharge extra parameters
parameter | type | description | ||||
---|---|---|---|---|---|---|
|
string |
The total price of the purchase. This includes
|
||||
|
string |
The retail price of the purchase before promotion, tax, download fee, and any other associated fees.
|
||||
|
string |
The calculated tax to be charged. The value of this parameter must be greater than or equal to
|
||||
|
string |
The calculated promotion to be credited against the
|
||||
|
string |
The promotional percentage to be applied to the
|
||||
|
string |
The download fee amount to be charged.
|
||||
|
string |
The download fee amount without tax to be charged.
|
||||
|
string |
The customer’s region. This field is provided for compatibility purposes and is overwritten by the CRS with the value retrieved from the relevant SPR for this subscriber.
|
||||
|
string |
Indicates if the customer is prepaid or postpaid. This field is provided for compatibility purposes and is overwritten by the CRS with the value retrieved from the relevant SPR for this subscriber.
|
||||
|
varchar(50) |
The ID of the provider obtained from the provider ID list.
|
||||
|
varchar(50) |
The sales branch associated with the product ID.
|
||||
|
varchar(50) |
The sales person from the
|
||||
|
varchar(50) |
The method used for activating the service.
|