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

fume-fhir-converter

v3.0.6

Published

FHIR-Utilized Mapping Engine - Community

Downloads

314

Readme

FUME Community (fume-fhir-converter) — v3

npm version docker image version

FUME Community is an open-source FHIR® conversion + mapping engine (and a standalone HTTP server) built around the FUME language.

What’s new in v3

This is a major release focused on correctness, diagnostics, and runtime scalability:

  • Better automatic conformance (injecting system and display values), deeper structural and terminology validations
  • Better diagnostics and behavior-control knobs (validation thresholds, throwLevel, etc.)
    • verbose mode returns a detailed evaluation report
  • Improved caching and concurrency support
  • Syntax improvements in the FUME language
  • Accurate position pointers in errors
  • File-based mappings (*.fume files) in addition to server-hosted StructureMap resources
  • Improved performance

Quick links

TL;DR: a full FHIR resource from 3 numbers

This example turns a tiny JSON payload into a fully-conformant Blood Pressure Observation (InstanceOf: bp) and demonstrates FUME's automatic conformance (injected codes, units, etc.).

Expression:

Instance: $uuid()
InstanceOf: bp
* status = 'final'
* effectiveDateTime = $now()
* subject.identifier.value = mrn
* component[SystolicBP].value = systolic
* component[DiastolicBP].value = diastolic

Input:

{
	"mrn": "PP875023983",
	"systolic": 120,
	"diastolic": 80
}

Example output (one run). Note: id and effectiveDateTime will differ because they come from $uuid() and $now():

{
	"resourceType": "Observation",
	"id": "3c91d1da-894c-4e5e-b400-93121a2043e9",
	"meta": {
		"profile": [
			"http://hl7.org/fhir/StructureDefinition/bp"
		]
	},
	"status": "final",
	"category": [
		{
			"coding": [
				{
					"system": "http://terminology.hl7.org/CodeSystem/observation-category",
					"code": "vital-signs",
					"display": "Vital Signs"
				}
			]
		}
	],
	"code": {
		"coding": [
			{
				"system": "http://loinc.org",
				"code": "85354-9"
			}
		]
	},
	"subject": {
		"identifier": {
			"value": "PP875023983"
		}
	},
	"effectiveDateTime": "2026-02-16T23:50:49.527Z",
	"component": [
		{
			"code": {
				"coding": [
					{
						"system": "http://loinc.org",
						"code": "8480-6"
					}
				]
			},
			"valueQuantity": {
				"value": 120,
				"unit": "millimeter of mercury",
				"system": "http://unitsofmeasure.org",
				"code": "mm[Hg]"
			}
		},
		{
			"code": {
				"coding": [
					{
						"system": "http://loinc.org",
						"code": "8462-4"
					}
				]
			},
			"valueQuantity": {
				"value": 80,
				"unit": "millimeter of mercury",
				"system": "http://unitsofmeasure.org",
				"code": "mm[Hg]"
			}
		}
	]
}

How to run this example:

  • Use the public playground. Paste input in the left pane, expression in the top-right pane, and watch the results in bottom-right pane
  • HTTP server (ad-hoc): POST / with { fume, input }
  • HTTP server (saved mapping): configure a mapping folder, save the expression as bpDemo.fume and POST /Mapping/bpDemo
  • Node library: engine.transform(input, expression) or engine.transformVerbose(...)

See docs/getting-started.md and docs/http-api.md for copy/paste invocation snippets.

Use as a library (Node)

Create a FumeEngine and call transform():

import { FumeEngine } from 'fume-fhir-converter';

const engine = await FumeEngine.create({
	config: {
		FHIR_SERVER_BASE: 'n/a',
		FHIR_VERSION: '4.0.1',
		FHIR_PACKAGES: '[email protected]'
	}
});

const out = await engine.transform(input, expression);

Note: when embedding as a module, FUME does not read process.env / .env automatically. Pass config explicitly.

Run as an HTTP server

See docs/getting-started.md for deployment options, including Docker.

The HTTP API is documented here: docs/http-api.md

License

AGPL-3.0