Support for

FLAPI: About Production and Runs

Alistair Wilson
by Alistair Wilson 7 years ago
 

Checking your ‘in-box’

w3p automatically assigns jobs to your workgroup when they are ordered by customers. These jobs are packaged in runs, the objects that track production.

Periodically poll your list of runs, with criteria: state=production and days=<despatch target>

HTTP request
GET https://dev.flyerlink.com/api.php/runs?state=production&days=10&format=json

Starting work

Examine a run, to get the specifications of all its jobs (there is usually just one job in a run).

HTTP request
GET https://dev.flyerlink.com/api.php/runs/1234/jobs?format=json

Claim the run with ‘accept’ call:

HTTP request
POST https://dev.flyerlink.com/api.php/runs/1234/accept
format=json

The locations of artwork files are detailed in each job object in the above GET /runs/.../jobs/ call.

Now do what you do best: convert the order into goods or services, and then process your items for despatch. Inform w3p that this is done by logging the despatch (see Despatching, below).

Aborting a job

If something 'abortive' happens during production of a job, you can remove it from its run

Either you or the studio can then make changes before it does to production again (status 081)

Note for admins

When a job.status is set to 081, and the run type should be configured to be ‘auto-allocating’, then the job will be allocated immediately to a new run.

Just deallocate - make API changes

If you want to change the job, but the job is locked.

First deallocate the job and then make changes using PUT /jobs API requests.

HTTP request
POST https://dev.flyerlink.com/api.php/runs/1234/jobs/5678/deallocate

OR (alias)

HTTP request
POST https://dev.flyerlink.com/api.php/jobs/5678/deallocate

Deallocate & status 091 - require changes from design studio

To require a studio to make changes provide a costing and reason as url parameters

The studio will then be notified the job has been sent to status 091 and requires changes before it can be produced.

HTTP request
POST https://dev.flyerlink.com/api.php/runs/1234/jobs/5678/deallocate
?costing=CAN&reason=My%20Reason

OR (alias)

HTTP request
POST https://dev.flyerlink.com/api.php/jobs/5678/deallocate
?costing=CAN&reason=My%20Reason

Despatching

Immediately before despatching, get the despatch specification again, in case it has changed since calling GET /runs/1234/jobs

Use the POST /job/…/despatch request to register that you have physically packed and processed a job for despatch.

HTTP request
POST https://dev.flyerlink.com/api.php/jobs/<job.id>/despatch
line=2316091&quantity=1000&boxes=1&run=12345

Other Queries

Has a job been despatched?

HTTP request
GET https://dev.flyerlink.com/api.php/jobs/<job.id>/despatch

What runs have been completed?

HTTP request
GET https://dev.flyerlink.com/api.php/runs?state=production&days=10
 

Jump to contents page of

Flyerlink API Guide

 
 
 

All content is (c) Nettl Systems Limited, 2024 and may not be used, copied or distributed without permission.