Using Cost Models - PaperCutSoftware/PaperCutExamples GitHub Wiki
PaperCut MF/NG allows a lot flexibility in setting various
cost models for printers and copiers,
see the tab Printers
-> Select printer -> Charging
.
For the following information to make sense you need to be
familiar with the setup of cost models in the PaperCut MF/NG
admin interface. More information at https://www.papercut.com/support/resources/manuals/ng-mf/applicationserver/topics/printer-diff-charging.html
So setting up printer charging is a two stage process
- Define the details of a cost model
- Select that cost model for use on the printer.
PaperCut supports six different cost models, which have different names depending on where you are:
Name in Web Interface | Value returned by get-printer-property cost-model
|
name in advanced attribute |
---|---|---|
simple | SIMPLE | n/a (see below) |
standard | SIZE_TABLE | pst |
by paper size category | SIZE_CATEGORY | psc |
by paper sizes | SIZE_DETAILED | psi |
by paper length | SIZE_LENGTH | length |
by paper area | AREA | area |
This is easy -- use the server-command sub command set-printer-cost-simple
. For example
server-command set-printer-cost-simple laptop-alec fake_printer 0.03
If the charge model is set to standard then the costs are defined in a series of attributes, one for each combination of paper size, color or greyscale, and simplex or duplex. So for instance
advanced-config.cost.pst.11x17.color.simplex
The first group of attributes set the costs for the default paper size
advanced-config.cost.pst.default.color.duplex
advanced-config.cost.pst.default.color.simplex
advanced-config.cost.pst.default.grayscale.duplex
advanced-config.cost.pst.default.grayscale.simplex
advanced-config.cost.pst.default.enabled
Then for each set of paper sizes that do not use the default cost model a set of custom costs must be defined. So for instance
advanced-config.cost.pst.letter.color.duplex
advanced-config.cost.pst.letter.color.simplex
advanced-config.cost.pst.letter.grayscale.duplex
advanced-config.cost.pst.letter.grayscale.simplex
Additionally each paper size must be enabled with an additional attribute. For example
advanced-config.cost.pst.letter.enabled
set to "Y
". It can be set to "N
" to disable the costs for the corresponding paper size.
Note that the default
paper size must also have an enabled attribute set
(See the example for default
above)
For information on duplex discount see https://www.papercut.com/support/resources/manuals/ng-mf/applicationserver/topics/printer-diff-charging.html#printer-duplex-discount-calculation
Set values for the following attributes
-
advanced-config.cost.psc.duplex.type
"LESS_PER_PAGE" -
advanced-config.cost.psc.duplex.value
"0.0" -
advanced-config.cost.psc.grayscale.type
"LESS_PER_PAGE" -
advanced-config.cost.psc.grayscale.value
"0.0" -
advanced-config.cost.psc.large.type
"EXTRA_PER_PAGE" -
advanced-config.cost.psc.large.value
"0.0" -
advanced-config.cost.psc.verylarge.type
"EXTRA_PER_PAGE" -
advanced-config.cost.psc.verylarge.value
"0.0"
Alternatively this can be configured as a percentage
-
advanced-config.cost.psc.duplex.type
"PERCENT_LESS" -
advanced-config.cost.psc.duplex.value
"10.0" -
advanced-config.cost.psc.grayscale.type
"PERCENT_LESS" -
advanced-config.cost.psc.grayscale.value
"5.0" -
advanced-config.cost.psc.large.type
"PERCENT_EXTRA" -
advanced-config.cost.psc.large.value
"10.0" -
advanced-config.cost.psc.verylarge.type
"PERCENT_EXTRA" -
advanced-config.cost.psc.verylarge.value
"20.0"
First define costs for a default colour and greyscale page
-
advanced-config.cost.cost.psi.grayscale.default
"0.03" -
advanced-config.cost.cost.psi.color.default
"0.03"
Next define the discount for duplex (both type and value)
-
advanced-config.cost.psi.duplex.discount.type
"LESS_PER_PAGE" or -
advanced-config.cost.psi.duplex.discount.type
"PERCENT_LESS"
Then custom costs can be added for each page size that is different to the default. For example
-
advanced-config.cost.psi.grayscale.a4
"0.02" -
advanced-config.cost.psi.color.a4
"0.01"
For information on duplex discount see https://www.papercut.com/support/resources/manuals/ng-mf/applicationserver/topics/printer-diff-charging.html#printer-duplex-discount-calculation
-
advanced-config.cost.length.cost.unit
"PER_FOOT" or "PER_METRE" -
advanced-config.cost.length.cost.value
"0.30" -
advanced-config.cost.length.duplex.type
"LESS_PER_PAGE" or "PERCENT_LESS" -
advanced-config.cost.length.duplex.value
"3.0" -
advanced-config.cost.length.grayscale.type
"LESS_PER_PAGE" or "PERCENT_LESS" -
advanced-config.cost.length.grayscale.value
"7.5"
For information on duplex discount see https://www.papercut.com/support/resources/manuals/ng-mf/applicationserver/topics/printer-diff-charging.html#printer-duplex-discount-calculation
-
advanced-config.cost.area.cost.unit
"PER_SQUARE_FOOT" or "PER_SQUARE_METRE" -
advanced-config.cost.area.cost.value
"0.03" -
advanced-config.cost.area.duplex.type
"LESS_PER_PAGE" or "PERCENT_LESS" -
advanced-config.cost.area.duplex.value
"0.3" -
advanced-config.cost.area.grayscale.type
"LESS_PER_PAGE" or "PERCENT_LESS" -
advanced-config.cost.area.grayscale.value
"7.5"
As of PaperCut NG/MF 19.1, You can apply cost models via the server-command and web services API:
server-command set-printer-property l-ryanr.papercutsoftware.com toshiba2505 cost-model SIZE_LENGTH
Otherwise, you will have to set these changes through the Admin UI.