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

@mostajs/medical-cases

v0.2.0

Published

Cœur métier MINCE de dossier patient + examens + circuit de prise en charge (imagerie/biologie/anapath). DB-agnostique ; COMPOSE nomenclature (cim-10/ccam), ged, image, statemachine, booking, aid-grants, numbering, audit. Générique santé (P3 Salsabil).

Readme

@mostajs/medical-cases

Auteur : Dr Hamid MADANI [email protected] · Licence : AGPL-3.0-or-later

Cœur métier mince : dossier patient + examens + circuit de prise en charge (imagerie / biologie / anatomopathologie). DB-agnostique. Compose (jamais ne réimplémente) : @mostajs/nomenclature (diagnostic CIM-10 / examen CCAM), @mostajs/ged (documents), @mostajs/image (imagerie), @mostajs/statemachine, @mostajs/booking-stack, @mostajs/aid-grants (financement), @mostajs/numbering, @mostajs/audit.

Données de santé = secret médical : voir §11.3 (informatif) — base légale, minimisation, chiffrement au repos (storage), résidence pilotée par .env.

Install

npm i @mostajs/medical-cases

Exemple minimal

import { createMedicalCases, createMemoryRepositories } from '@mostajs/medical-cases';
// Codification santé (chacun son métier) : injecter @mostajs/nomenclature seedé HEALTH_SEEDS.
// import { createNomenclature, HEALTH_SEEDS } from '@mostajs/nomenclature';
// const nomenclature = createNomenclature({ repositories, dataset: HEALTH_SEEDS, defaultScheme: 'cim-10' });

const m = createMedicalCases({ repositories: createMemoryRepositories() /*, nomenclature, ged, aidGrants, booking */ });

const c = await m.cases.open({ patient: { name: 'Fatima Z.' }, diagnosis: 'C50', physician: 'Dr Benali', facility: 'CAC' });
await m.documents.add(c.id, { gedDocId: 'ged-cr-001', kind: 'CR' });
const e = await m.exams.request(c.id, { type: 'IMG-TDM', category: 'imaging' }); // crée le bulletin
await m.exams.realize(e.id);
await m.exams.result(e.id, { gedDocId: 'ged-res-001' });
await m.cases.advance(c.id); // circuit de prise en charge (9 étapes → clôture)

API (0.1.0)

  • createMedicalCases({ repositories, nomenclature?, ged?, image?, statemachine?, booking?, aidGrants?, numbering?, audit?, now? })
  • cases : open({patient,diagnosis?,physician?,facility?,caregiver?}) · get · list(filter) · listByStatus(s) · advance(id) · setStatus(id,s) · close(id,{outcome})
  • documents : add(id,{gedDocId,kind?,label?}) · list(id)
  • exams : request(caseId,{type,category?}) (→ bulletin) · get · listByCase · realize(examId) · result(examId,{gedDocId})
  • dashboard() · reportingSource() (→ @mostajs/reporting)
  • cycle (9 étapes) · categories (= EXAM_CATEGORIES) · statusLabel(s) (7 statuts métier)
  • createMemoryRepositories() · PatientCaseSchema, ExamSchema

Codification (composer @mostajs/nomenclature)

Si nomenclature est injecté, diagnosis est validé en cim-10 et exams.request().type en ccam (sinon saisie libre — dégradation gracieuse). Côté app santé : seeder HEALTH_SEEDS.

Tests & exemple

npm test (@mostajs/mjs-unit, 6 tests) · npm run example (parcours de prise en charge, assertions).