Getting proof is a 2-step process.
- Generate the proof on the server: You call the API https://rest.click2mail.com/molpro/jobs/{{jobId}}/proof -- This will return you the proofID and a URL to download the proof
- Download the proof PDF
You can do this by calling the URL returned by the above call. This is a secure URL and works without giving credentials. It is used to display the proof to the user in their browser. The URL is valid till the duration of the "session", i.e. while you are logged in to your account. Once you logout, or after 15 min of inactivity, the URL invalidates itself. This method of proof display is useful if you are building a webapp where your users can see the proof. The other method is to call the API https://rest.click2mail.com/molpro/jobs/{{jobId}}/proof/{{proofId}} This API calls requires you to send your credentials (just like you do for the other API calls).
Notes: A nuance that may be useful to you. If you generate the proof after submitting the job, it will have a timestamp and job-id. This is useful if you want to archive the proof. If you generate the proof before submitting the job, it will not have the timestamp/job-id.
Carly Brown
Comments