Status: Difference between revisions

From Safe Creative API
Jump to navigation Jump to search
w>Jguillo
w>Jguillo
Line 35: Line 35:
https://web.safestamper.com/api/status
https://web.safestamper.com/api/status
?sharedkey=5hmpod0d2vx7fnh6ysxab3olz
?sharedkey=5hmpod0d2vx7fnh6ysxab3olz
&jobId=f39f2d5c-4bc6-4a15-90b5-00ebf69d0268
&jobId=c498d3e0-aedb-48fe-82d5-5dec4270318b
&signature=33e27a515f1478d00abcce577205e2f54e6d94f2
&signature=5784ad59c9fb400451887a138bf8ad36cee729d2
</pre>
</pre>


RESPONSE:
RESPONSE (actual response has no line breaks or indentation):
<pre>
<pre>
{
{
   "jobId":"f39f2d5c-4bc6-4a15-90b5-00ebf69d0268",
   "jobId":"c498d3e0-aedb-48fe-82d5-5dec4270318b",
   "results":[
   "results":[
       {"url":"www.safestamper.com","status":"READY","certificateId":"160419-N3MBMN","certificateUrl":"https://web.safestamper.com/certificate/160419-N3MBMN"},
       {"url":"http://www.safestamper.com","status":"READY","certificateId":"160419-BQS763","certificateUrl":"https://web.safestamper.com/certificate/160419-BQS763"},
       {"url":"www.safecreative.org","status":"INPROGRESS"}
      {"url":"NON-VALID-URL","status":"ERROR","error":"bad-url"},
       {"url":"http://www.safecreative.org","status":"INPROGRESS"}
   ]
   ]
}
}
</pre>

Revision as of 10:45, 19 April 2016

This operation returns the status of a certification job.

URL

https://web.safestamper.com/api/status

Parameters

Returns

A JSON object with the following fields:

  • jobId: Job identifier
  • results: Array of JSON objects with the status of each URL included in the certification job
    • url: URL to be certified
    • status: URL status, can be one of the following:
      • INPROGRESS: The URL has not been certificated yet
      • ERROR: The URL could not be certified
      • READY: The URL certificate is ready for download
    • error: Error description (for ERROR status)
    • certificateId: Certificate code (for READY status)
    • certificateUrl: Certificate download URL (for READY status)

HTTP Errors

  • 403 Forbidden: the sharedkey or signature are not valid, or the specified job does not belong to the API client
  • 404 Not found: the job id is not correct.

Example

REQUEST:

https://web.safestamper.com/api/status
?sharedkey=5hmpod0d2vx7fnh6ysxab3olz
&jobId=c498d3e0-aedb-48fe-82d5-5dec4270318b
&signature=5784ad59c9fb400451887a138bf8ad36cee729d2

RESPONSE (actual response has no line breaks or indentation):

{
   "jobId":"c498d3e0-aedb-48fe-82d5-5dec4270318b",
   "results":[
      {"url":"http://www.safestamper.com","status":"READY","certificateId":"160419-BQS763","certificateUrl":"https://web.safestamper.com/certificate/160419-BQS763"},
      {"url":"NON-VALID-URL","status":"ERROR","error":"bad-url"},
      {"url":"http://www.safecreative.org","status":"INPROGRESS"}
   ]
}