Hi Roland,
thanks for posting these scripts. I’m interested more in the Webhook one - I find it much easier to learn how to code by reading and understanding examples than by reading the documentation.
I have 2 questions though:
-
You only process print jobs that were terminated normally, i.e. $obj->{‘details’}->{‘log’}->{‘stopType’} == ‘normal’. Of course the bridge turns off automatically when the job is finished/stopped, so most cases should have stopType==normal. Are there cases you need to exclude with this check? Shouldn’t all log entries with a metadata field “price” be charged?
-
This webhook is called after the time-based price is calculated, is correct? Therefore you overwrite the calculated price, if there is any?