Job Status

get_job_status method

Sometimes, you may want to get a particular job status at a later time. You may use the get_job_status function to do this:

You will already have your Web Api class initialised as follows:

WebApi connection = new WebApi(<String partner_id>, <String default_callback_url>, <String decoded_version_of_api_key>, <Integer 0 || 1>);

Thereafter, simply call get_job_status with the correct parameters using the classes we have provided:

// create the stringified json for the partner params using our class (i.e. user_id, job_id, and job_type that you would are querying)
PartnerParameters partnerParameters = new PartnerParameters(<String user_id>, <String job_id>, <Integer job_type>);
// create the options - whether you would like to return_history and return_image_links in the job status response
Options job_status_options = new Options(<Boolean return_history>, <Boolean return_image_links>);
response = connection.get_job_status(partnerParameters.get(), job_status_options.get());

Please note that if you do not need to pass through Options if you will not be using them, you may omit calling those class and send through null instead:

String response = connection.get_job_status(partnerParameters.get(), null);