Choose your language

Choose your login

Support

How can we help?

Lightbulb icon
Lightbulb icon

Here’s your answer

Sources:

Lightbulb icon

Oops!

We currently don’t have an answer for this and our teams are working on resolving the issue. If you still need help,
User reading a resource

Popular resources

Conversation bubbles

Contact us

Import print job details

This page applies to:

You can import print jobs that have been tracked by external or third party systems into PaperCut NG/MF. This could be because the external system is not easily tracked directly, or to import data that was previously tracked for logging and reporting purposes.

Job details can be imported using the server-command scripting tool (process-job command, see Server commands (server-command) ) or using the web services API (api.processJob call, see The XML Web Services API ). To import multiple jobs in a batch, run the command/call multiples times (e.g. via a script or program).

The server-command and web services call accept a single argument (string) containing all the job details. Each field is specified as a name-value pair separated by an equals sign (i.e. name=value), and fields are separated by commas.

For example, to process a job and specify the user, printer server and printer name (the minimum required details):

user=bob,server=papercut,printer=My Printer

If any fields contain a comma, surround the name-value pair with quotation marks ("). E.g. for a printer named Library, rear:

user=bob,server=papercut,"printer=Library, rear"

Spreadsheet applications such as Excel with automatically add quotation marks as above when saving a document in CSV format.

If any fields contain quotation marks, escape them by adding another quotation mark, i.e. two in a row. E.g. for a printer named "John Smith" Library:

user=bob,server=papercut,printer=""John Smith"" Library

The names of all the available fields are listed in the table below.

Fields for Importing Print Job Details

FieldRequiredDescriptionDefault
userYesThe username of the user associated with the job.N/A
serverYesThe name of the server the job was submitted to.N/A
printerYesThe name of the printer or print queue the job was submitted to.N/A
timeNoThe time the job was submitted/printed. This is formatted as an ISO8601 simple date-time: yyyyMMddTHHmmss. E.g. "20091224T133602" represents the 24th of December 2009 at 13:36:02 (1:36 pm, local time).(current time)
costNoThe cost of the job. If the cost is not set it is automatically calculated as for a normal job (based on the job details and configuration of the printer, user etc.).(auto)
total-pagesNoThe total number of pages in the job.1
total-color-pagesNoThe total number of color pages in the job.(same as total-pages)
copiesNoThe number of copies in the job.1
document-nameNoThe document name.(empty)
duplexNoTRUE or FALSE to indicate if the job is duplex (printed on both sides)FALSE
grayscaleNoTRUE or FALSE to indicate if the job is grayscale (no color)FALSE
job-typeNoThe type of job to import. Options include: COPY, FAX, PRINT, SCAN.PRINT
paper-size-nameNoThe name of a standard paper size, e.g. "Letter" or "A4".(empty)
paper-width-mmNoThe width of the paper in millimeters. Determined automatically if using paper-size-name.(empty)
paper-height-mmNoThe height of the paper in millimeters. Determined automatically if using paper-size-name.(empty)
document-size-kbNoThe size of the document's spool file in kilobytes.0
invoiceNoTRUE to mark the job as invoiced, FALSE to mark as not invoiced. The default value is determined automatically, as for a regular job.(auto)
commentNoA comment to be associated with the job.(empty)
client-machineNoThe hostname of the client machine the job was submitted from.(empty)
client-ipNoThe IP address of the client machine the job was submitted from.(empty)
shared-accountNoThe name of the shared account to charge this job to. Sub-accounts can be selected using a backslash, i.e. "parent\child".(empty)

Comments