npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@transai/connector-runner-hp-indigo

v0.10.0

Published

Connector runner for **HP Indigo** digital printing presses. Connects via JMF (Job Messaging Format) persistent query subscriptions and forwards job status, device status, resource, and heartbeat events to the transAI platform as metrics.

Downloads

301

Readme

HP Indigo Connector Runner

Connector runner for HP Indigo digital printing presses. Connects via JMF (Job Messaging Format) persistent query subscriptions and forwards job status, device status, resource, and heartbeat events to the transAI platform as metrics.

How it works

  1. On start() the connector launches a local HTTP server to receive callbacks.
  2. For each configured machine it optionally checks JMF capability (KnownMessages).
  3. It retrieves already-active subscriptions and skips those already registered.
  4. For remaining subscription types it sends JMF persistent-query subscribe requests.
  5. An initial queue snapshot is sent immediately after queueStatus subscription.
  6. Incoming JMF signals are parsed and forwarded as metrics, enriched with machineId, machineName (if set), and printerId.
  7. On stop() it sends JMF StopPersistentChannel to unsubscribe all callbacks.

Configuration

Minimal

{
  "connectorType": "hp-indigo",
  "callbackHost": "192.168.1.10",
  "machines": [
    {
      "machineId": "indigo-01",
      "printerUrl": "http://192.168.1.50:8080/prodflow/jmf/printer1"
    }
  ]
}

Full configuration

{
  "connectorType": "hp-indigo",
  "callbackHost": "192.168.1.10",
  "port": 3050,
  "webhookPath": "/hp-indigo",
  "collections": {
    "queueStatus": "hp_indigo_queue",
    "status": "hp_indigo_status",
    "resource": "hp_indigo_resource"
  },
  "machines": [
    {
      "machineId": "indigo-01",
      "machineName": "HP Indigo Floor 1",
      "printerUrl": "http://192.168.1.50:8080/prodflow/jmf/printer1",
      "checkCapabilities": true,
      "subscriptions": {
        "queueStatus": true,
        "status": true,
        "heartbeat": true,
        "heartbeatInterval": 30,
        "resource": true
      }
    }
  ]
}

Configuration fields

Root level:

{
  "callbackHost": "Required — IP or hostname reachable from the printer",
  "port":         "Webhook server port — default: 3050",
  "webhookPath":  "Base path for webhook endpoints — default: /hp-indigo",
  "collections": {
    "queueStatus": "Collection for job/queue status messages",
    "status":      "Collection for device status messages",
    "resource":    "Collection for resource/consumable messages"
  },
  "machines": "Required — array of machine configurations"
}

Per machine:

{
  "machineId":           "Required — unique identifier, added to every metric",
  "printerUrl":          "Required — HP Indigo JMF endpoint URL",
  "machineName":         "Optional — human-readable display name, added to every metric",
  "checkCapabilities":   "Query printer for JMF support before subscribing — default: true",
  "subscriptions": {
    "queueStatus":       "Subscribe to job queue updates — default: true",
    "status":            "Subscribe to device status updates — default: true",
    "heartbeat":         "Subscribe to periodic heartbeat signals — default: true",
    "heartbeatInterval": "Heartbeat interval in seconds — default: 30",
    "resource":          "Subscribe to resource/consumable updates — default: true"
  }
}

Multiple machines

{
  "connectorType": "hp-indigo",
  "callbackHost": "192.168.1.10",
  "machines": [
    {
      "machineId": "indigo-01",
      "machineName": "HP Indigo Floor 1",
      "printerUrl": "http://192.168.1.50:8080/prodflow/jmf/printer1"
    },
    {
      "machineId": "indigo-02",
      "machineName": "HP Indigo Floor 2",
      "printerUrl": "http://192.168.1.51:8080/prodflow/jmf/printer2"
    }
  ]
}

Webhook-only mode

When no machines are configured the connector starts in webhook-only mode — no JMF subscriptions are created.

{
  "connectorType": "hp-indigo",
  "port": 3050
}

HP Indigo must then be configured to POST directly to:

POST http://<connector-host>:3050/hp-indigo/queue-status?machineId=<machine-id>
POST http://<connector-host>:3050/hp-indigo/status?machineId=<machine-id>
POST http://<connector-host>:3050/hp-indigo/heartbeat?machineId=<machine-id>
POST http://<connector-host>:3050/hp-indigo/resource?machineId=<machine-id>

Webhook endpoints

All endpoints expect Content-Type: application/vnd.cip4-jmf+xml. The machineId query parameter routes the signal to the correct machine handler. When only one machine is configured it is used as fallback if machineId is absent.

POST <webhookPath>/queue-status?machineId=<machine-id>
POST <webhookPath>/status?machineId=<machine-id>
POST <webhookPath>/heartbeat?machineId=<machine-id>
POST <webhookPath>/resource?machineId=<machine-id>

Machine metadata

Every metric sent to the platform includes:

{
  "jobId": "abc123",
  "jobStatus": "Running",
  "machineId": "indigo-01",
  "printerId": "indigo-01",
  "machineName": "HP Indigo Floor 1"
}

machineName is omitted when not set. collection is added when configured at root level.

Collections

Messages are routed to root-level collections — shared across all machines.

{
  "collections": {
    "queueStatus": "hp_indigo_queue",
    "status":      "hp_indigo_status",
    "resource":    "hp_indigo_resource"
  }
}

If a collection is not set the platform default is used.

Monitoring & health

Health checks run every 5 minutes per machine.

With heartbeat enabled:

  • Missing for more than 2 minutes → WARN
  • After 3 consecutive missed checks, printer still reachable → ERROR: check firewall
  • After 3 consecutive missed checks, printer unreachable → ERROR: printer may be offline
  • Heartbeat missing but job data still arriving → WARN: data flow healthy
  • Recovered → INFO

Without heartbeat:

  • No notifications for more than 15 minutes → WARN (may be normal when idle)

Troubleshooting

No subscriptions created

  • Verify printerUrl is accessible from the connector host
  • Set checkCapabilities: false to skip the JMF capability check
  • Omit machines to use webhook-only mode

HP Indigo not sending webhooks

# Test reachability from the printer network
curl -X POST "http://<connector-host>:3050/hp-indigo/heartbeat?machineId=test" \
  -H "Content-Type: application/vnd.cip4-jmf+xml" \
  -d '<?xml version="1.0"?><JMF xmlns="http://www.CIP4.org/JDFSchema_1_1"><Signal Type="Status"/></JMF>'

Testing webhooks locally

# Queue-status
curl -X POST "http://localhost:3050/hp-indigo/queue-status?machineId=indigo-01" \
  -H "Content-Type: application/vnd.cip4-jmf+xml" \
  -d '<?xml version="1.0"?>
<JMF xmlns="http://www.CIP4.org/JDFSchema_1_1">
  <Signal Type="Status">
    <QueueStatus>
      <QueueEntry JobID="test-job" DescriptiveName="test.pdf" Status="Running"/>
    </QueueStatus>
  </Signal>
</JMF>'

# Heartbeat
curl -X POST "http://localhost:3050/hp-indigo/heartbeat?machineId=indigo-01" \
  -H "Content-Type: application/vnd.cip4-jmf+xml" \
  -d '<?xml version="1.0"?><JMF xmlns="http://www.CIP4.org/JDFSchema_1_1"><Signal Type="Status"/></JMF>'

Documentation

Building

npx nx build connector-runner-hp-indigo

Testing

npx nx test connector-runner-hp-indigo