Endpoints
We'll have two endpoints:
- REST (GET/POST): /services/rest/user/creditBalance?username=[]&password=[]
- SOAP: /services/ws/user?wsdl (method: creditBalance)
<soapenv:Envelope xmlns:soapenv= "http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser= "http://server.submission.mc5.smspl.com/" > <soapenv:Header/> <soapenv:Body> <username>?</username> <password>?</password> </soapenv:Body> </soapenv:Envelope> |
What information to return?
For the REST endpoint (JSON)
{ "creditBalance" : "100" , "errorCode" : "-200" , } |
For the SOAP endpoint (XML):
<soap:Body> < return > <creditBalance> 100 </creditBalance> <errorCode>- 200 </errorCode> </ return > </soap:Body> </soap:Envelope> |
errorCode and creditBalance are exclusive (only one field is present in the actual response)