Webservices
GetCOCDetails
Test
The test form is only available for requests from the local machine.SOAP 1.1
The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
Request Sample
POST /v3/webservices.asmx HTTP/1.1 Content-Type: text/xml; charset=utf-8 Content-Length: length SOAPAction: "https://www.shafafiya.org/v2/GetCOCDetails" <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="https://www.shafafiya.org/v2/"> <soapenv:Header/> <soapenv:Body> <v2:GetCOCDetailsForPayerRequest> <v2:login>string</v2:login> <v2:pwd>string</v2:pwd> <!-- Pass either one of the param --> <v2:EmiratesIDNumber>784-1234-1234567-8</v2:EmiratesIDNumber> <v2:UnifiedNumber>string</v2:UnifiedNumber> <v2:BirthCertificateNumber>string</v2:BirthCertificateNumber> <v2:ReferenceNumber>string</v2:ReferenceNumber> </v2:GetCOCDetailsForPayerRequest> </soapenv:Body> </soapenv:Envelope>
Response Sample 1
HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8 Content-Length: length <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="https://www.shafafiya.org/v2/"> <soapenv:Header/> <soapenv:Body> <v2:GetCOCDetailsForPayerResponse> <v2:ReferenceNumber>12345678</v2:ReferenceNumber> <v2:TotalPenalty>500</v2:TotalPenalty> <v2:ValidityDate>string</v2:ValidityDate> <v2:COCStatus>string</v2:COCStatus> <v2:Persons> <v2:Person> <v2:EmiratesIDNumber>string</v2:EmiratesIDNumber> <v2:UnifiedNumber>string</v2:UnifiedNumber> <v2:NonInsuranceDays>string</v2:NonInsuranceDays> <v2:Penalty>string</v2:Penalty> <v2:PolicyExpiryDate>string</v2:PolicyExpiryDate> </v2:Person> </v2:Persons> <v2:ResponseCode>0</v2:ResponseCode> <v2:ResponseDescription>Success</v2:ResponseDescription> </v2:GetCOCDetailsForPayerResponse> </soapenv:Body> </soapenv:Envelope>
Response Sample 2
HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8 Content-Length: length <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="https://www.shafafiya.org/v2/"> <soapenv:Header/> <soapenv:Body> <v2:GetCOCDetailsForPayerResponse> <v2:ResponseCode>-1</v2:ResponseCode> <v2:ResponseDescription> No Existing COC details found for given input. Kindly use generate Insurance Continuity service to create COC</v2:ResponseDescription> </v2:GetCOCDetailsForPayerResponse> </soapenv:Body> </soapenv:Envelope>