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

maloident-api

v1.0.0

Published

Mock server for the MaLoIdent API used in German energy market communication

Readme

MaLoIdent API Mock Server

This project provides a mock implementation of the MaLoIdent API used in the German energy market for identifying market locations (Marktlokation or MaLo). This mock server specifically implements the negative response path for the market location data endpoint.

Overview

The MaLoIdent API is part of the German energy sector's market communication system, developed by EDI@Energy. It's used in the 24-hour supplier change process (LFW24) to query market location IDs and basic master data from network operators.

Features

  • Mock implementation of the /maloId/dataForMarketLocationNegative/v1 endpoint
  • Basic authentication using Bearer tokens
  • Request validation
  • Error handling

Requirements

  • Node.js
  • npm

Dependencies

  • Express.js - Web server framework
  • body-parser - Request body parsing middleware
  • cors - Cross-Origin Resource Sharing middleware

Installation

  1. Clone this repository
  2. Install dependencies:
npm install express body-parser cors

Usage

Starting the Server

node server.js

The server will start on http://localhost:3000

Test Client

A test client is provided to demonstrate how to interact with the API:

node test-client.js

Example Request

// POST to /maloId/dataForMarketLocationNegative/v1
{
  "identificationParameters": {
    "meterIdentificationNumber": "123456789",
    "marketLocationAddress": {
      "street": "Example Street",
      "houseNumber": "123",
      "postcode": "10115",
      "city": "Berlin",
      "country": "DE"
    }
  }
}

Example Response

{
  "decisionTree": "E_0594",
  "responseCode": "A10",
  "reason": "No market location found with the given parameters",
  "networkOperator": 9900987654321
}

API Documentation

POST /maloId/dataForMarketLocationNegative/v1

This endpoint is used to respond to market location identification requests when no matching market location is found or there's an error in processing the request.

Request Headers

  • Authorization: Bearer token for authentication

Request Body

  • identificationParameters: Object containing parameters to identify the market location
    • meterIdentificationNumber: The meter identification number
    • marketLocationAddress: Address information for the market location

Response

  • decisionTree: Code representing the decision path in the business process (e.g., "E_0594")
  • responseCode: Code representing the response type (e.g., "A10")
  • reason: Text description of the reason for the negative response
  • networkOperator: ID of the network operator

Limitations

This is a mock implementation with simplified validation and responses. In a production environment, the API would have:

  • Proper token validation
  • Integration with a database for market location lookup
  • More comprehensive business logic
  • Extensive error handling
  • Additional security measures

References

This implementation is based on the MaLoIdent API specification published by EDI@Energy and the German Federal Network Agency (Bundesnetzagentur) for the German energy market.

Maintainer / Impressum

License

This project is licensed under the Apache-2.0 License - see the LICENSE file for details.