When creating a parcel return policy, you have the option to request that your customers enter a return authorization (RA) number to retrieve a label. You can use one static number or provide us with a URL address to a web service that you host where your list of unique authorization numbers is housed.
When you create your parcel return policy in My Returns on the Canada Post website, if you select the web service option, you will be prompted to enter the URL, username and password for your web service. Here are the requirements for the web service.
Implementation
Your web service should be implemented using standard SOAP protocol and follow our WSDL.
We will call your web service to validate the RA number entered by your customers before we allow them to retrieve a return label. The web service must return either a pass or fail. If the authorization fails, we will not allow your customers to retrieve a return label.
Your web service should incorporate secure access. When we call your service, we will include the username and password in the WS-Security header as part of our SOAP call.
Please note that your web service must include the authorization number 99999999999999 (i.e., 14 9s), which should always return an indication of a valid number. This will allow Canada Post to ping your web service to determine that it is operational.
Successful completion
If your web service completes its actions successfully for the input data provided, you will return a 200-level HTTP code and respond with the output data contained within a top-level XML element in the SOAP body.