MLLP (HL7) implementation in Node.js
npm install mllp-node-sl7mllp
====
Fork, for original Readme see below!
Changes:
- Multi Message Support on a single Socket Connection
- Basic Character Encoding Support
- Timeout with Auto-Response
- Supports bind to all Interfaces (0.0.0.0)
- Using Package sb-sl7 for Message parsing
Sample (see example.js):
``javascript
var mllp = require('mllp-node');
var timeout = 600; // ms
var server = new mllp.MLLPServer('0.0.0.0', 1234, timeout);
// Subscribe to inbound messages
server.on('hl7', function (data){
console.log('received payload:', data);
});
// Send outbound messages
server.send('127.0.0.1', 4321, 'outbound-hl7-message', function (err, ackData) {
// async callback code here
});
`
Original Readme:



HL7's MLLP (Minimum Lower Layer Protocol) server implementation in Node.js.
Listen on predefined port for HL7 messages in format:
``
* HL7 MLP minimul layer protocol defined
* ACK message
- Node.js (v0.10+) and NPM
- Grunt.js
`you need Node.js and Grunt.js installed
Usage
See
example.js:`javascript
var mllp = require('mllp-node');var server = new mllp.MLLPServer('127.0.0.1', 1234);
// Subscribe to inbound messages
server.on('hl7', function (data){
console.log('received payload:', data);
});
// Send outbound messages
server.send('127.0.0.1', 4321, 'outbound-hl7-message', function (err, ackData) {
// async callback code here
});
``Contributors are welcome. See issues on GitHub issues
See release notes [here] (./RELEASENOTES.md)
Licensed under Apache 2.0