Dave Staas goes to Drupa to debut HP PrintOS APIs
Greetings from Dusseldorf, Germany, home to Drupa, the largest printing exposition in the world!
I am David Staas, the chief architect for HP PrintOS. All week at Drupa 2016 I have been explaining PrintOS to Print Service Providers from around the world.
PrintOS is HP’s open, secure, cloud-based platform. Our first release is focused primarily on HP Graphics devices and Print Service Providers. However, we welcome non-HP devices and services to be a part of the ecosystem, and so here at Drupa, we are releasing our first set of APIs.
If you'd like an overview of PrintOS before reading about the APIs, please see http://www.hp.com/go/printos.
PrintOS APIs fall into 2 main categories:
- Getting jobs into the system
- via PrintOS Box
- via PrintOS SiteFlow
- Adding devices
To request API access, go to the PrintOS page on the HP Developers Portal.
PrintOS Box APIs
PrintOS Box is a file transfer application optimized for print. The intent of PrintOS Box is to help Print Service Providers consolidate the influx of jobs from e-mail, web upload, DropBox, and WeTransfer into a single place. Incoming customer PDFs are preflighted automatically. Print shops can use Box to reply or interact with the customer directly and send the incoming files to production in a single click. Box supports sending jobs to any PrintOS device as well as to a generic hotfolder. Box is ideal for print shops managing 10-100 ad hoc and/or automated source jobs per day.
The PrintOS Box APIs allow content partners to send jobs into Box and make them visible in the same list as files coming in ad hoc from customers. This gives the print shop a single view of their incoming work, making life a lot easier on the prepress department.
PrintOS explained in 86 seconds
Here is how the PrintOS "Box" service simplifies work.
To request access to the Box API, go to the PrintOS page on the HP Developers Portal (hp.io)
PrintOS SiteFlow APIs
SiteFlow is a sophisticated and powerful application for print shops managing hundreds or even thousands of jobs a day. SiteFlow enables fully automated production through the print shop. It’s mostly intended for templated content, but handles ad hoc jobs as well. PrintOS already has a number of partners using the SiteFlow APIs to connect their content sources (W2P, MIS).
To request access to the SiteFlow API, go to the PrintOS page on the HP Developers Portal (hp.io)
With PrintOS device APIs, a device manufacturer can enable full PrintOS capability in their device. PrintOS-enabled devices can log in and send nearly real-time status updates for job count, device state, and expected time to completion. The typical scenario is as follows.
One time only:
- The device UI has a “cloud activate” screen that prompts the PSP administrator for their username and password.
- The device uses the PrintOS APIs to authenticate and receive its own credentials, which it should store securely. The device is added to the same organization as the PSP administrator.
- The device code logs out the administrator.
Each time the device is powered on:
- The device logs in to PrintOS using its own credentials
- Once authenticated, the device includes its session ID as a header on each call
- The device then sends status (every 1-2 minutes is recommended)
- The device must gracefully handle expired session IDs and any other errors
The device SDK also requires a PrintOS login in addition to access to the SDK so you can test it.
There are a few things you’ll want to know:
- The device type and model must already be present in the PrintOS database. If your model is not listed, please contact HP to have it added. You cannot specify arbitrary device types or models.
- For devices that require a serial number: a serial number for a specific device type and model must be unique across all organizations in PrintOS. If you try to register a device whose serial number is already in use by another organization, the registration will fail.
- If a device has issues, you can reregister the same serial number of the same device type and model to the same organization, the new registration will replace the previous one.
The system statistics service in PrintOS keeps the last 15 data points for a device’s real-time stats. In addition to the 3 standard fields (job count, device state, and time to completion), you can also send in whatever additional fields you want using the extendedInformation node. This is expected to be a set of key/value pairs that can be used in a future UI.
You can include whatever additional information you want, but please be sensitive to size – all of this data is sent to the UI whenever an update is done, so the payload should be kept small. (The maximum size is 64KB.)
Devices that use the PrintOS SDK should use reasonable precautions. These are questions your device client code should handle:
- What happens if the service goes offline for a few minutes?
- Can I handle any error code (503, 504, 500, maybe others? Anything in the 400 range?)
- Can I deal with a new added field I didn’t expect, or at least properly ignore it?
- Am I only using one connection per device?
- Am I limiting the interactions with the server to a reasonable level? Typically, device updates every 1-2 minutes are sufficient for a good user experience.
To request access to the Device API, go to the PrintOS page on the HP Developers Portal (hp.io).
Give Us Feedback
We welcome your feedback on the APIs. We’d also like to hear about future APIs you’d like to see exposed through the HP Developer Portal.
Other popular posts on the HP Developer Portal
- 7 Reasons Scala is better than Java...so why is Java winning?
- Print Fundamental Tutorials for Developers (Print good looking web pages)
- Crock Pot Lady monetizes recipes with Menu Plan printable
- Margaret Hamilton: Our favorite woman in code history
- "No more Yoda heads!" How 3D printing is like AWS
- Bridging from DevOps to Central Ops
- 3D printing a cup of coffee? Well...almost
- Women in Computer Science dropping since 1980
- An Allegory: Paper, Screen, Monty Python and the Holy Grail