Difference between revisions of "Get Job PDF"

From MyMobileWorkers API
Jump to: navigation, search
(Created page with "=== Get Job PDF === The MyMobileWorkers provides a tool for exporting PDFs from the job data. In some integration cases it may be easier to just pull the completed job down i...")
 
Line 1: Line 1:
 
=== Get Job PDF ===
 
=== Get Job PDF ===
  
−
The MyMobileWorkers provides a tool for exporting PDFs from the job data. In some integration cases it may be easier to just pull the completed job down in PDF format over importing the data into your database.
+
The MyMobileWorkers web portal provides a tool for exporting PDFs from the job data. In some integration cases it may be easier to just pull the completed job down in PDF format using the tool over importing the data into your database.
  
 
The tool provided to do this is part of the web portal and not the api, as such the URL is slightly different.
 
The tool provided to do this is part of the web portal and not the api, as such the URL is slightly different.
Line 31: Line 31:
 
| colspan="2" | PDF / JSON (on error)
 
| colspan="2" | PDF / JSON (on error)
 
|}
 
|}
 +
 +
 +
== Responses ==
 +
 +
In the event of a successful export generation the tool will return a 200 response, and a PDF to download.
 +
 +
In the event of an error the tool will return either a 401 or 500 error code. The HTTP response code should be used to decide if the PDF was generated correctly. If a 401 or 500 response is returned the headers will be of type 'application/json' and the error code structure will match the rest of the API.
 +
 +
== Caching ==
 +
 +
Generating PDFs via this tool can sometimes take an extended period to generate, its suggested that any PDFs generated are not streamed directly to your end users but saved on your server for downloading.

Revision as of 09:37, 22 October 2013

Contents

Get Job PDF

The MyMobileWorkers web portal provides a tool for exporting PDFs from the job data. In some integration cases it may be easier to just pull the completed job down in PDF format using the tool over importing the data into your database.

The tool provided to do this is part of the web portal and not the api, as such the URL is slightly different.

   http://live.mymobileworkers.com/api/

Its coding style is similar to API and returns the same set of error codes

Summary

Jobs
URL http://:base_url/api/job_export?api_key=YOUR_KEY&job_number=JOB_NUMBER
Type GET
Params: api_key required
job_number required
Response PDF / JSON (on error)


Responses

In the event of a successful export generation the tool will return a 200 response, and a PDF to download.

In the event of an error the tool will return either a 401 or 500 error code. The HTTP response code should be used to decide if the PDF was generated correctly. If a 401 or 500 response is returned the headers will be of type 'application/json' and the error code structure will match the rest of the API.

Caching

Generating PDFs via this tool can sometimes take an extended period to generate, its suggested that any PDFs generated are not streamed directly to your end users but saved on your server for downloading.

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox