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

@senacor/azure-function-middleware-openapi-generator

v0.2.0

Published

OpenAPI Generator for @senacor/azure-function-middleware

Readme

OpenAPI Generator for Azure Function Middleware

This tool generates an OpenAPI definition for an Azure Function App built with the @senacor/azure-function-middleware.

Installation

npm install @senacor/azure-function-middleware-openapi-generator --save-dev

Usage

Create a configuration file openapi-generation.config.json in the project's root directory:

{
  "apiDefinitions": [
    {
      "title": "My API",
      "outputFile": "api.yaml"
    }
  ]
}

See chapter configuration for more options.

Run the OpenAPI generator with:

npx @senacor/azure-function-middleware-openapi-generator

Configuration

The configuration is stored in the file openapi-generation.config.json. Every API is described by an ApiDefinitionConfiguration object stored in the apiDefinitions array.

Parameters for ApiDefinitionConfiguration:

| Name | Type | Required | Description | |----------------------------|------------------------|----------|-------------------------------------------------------------------------------| | title | string | x | Title of the API definition | | description | string | | Description for the API definition | | servers | ServerObject[] | | Details for the server section of the OpenAPI definition | | servers[].url | string | x | | | servers[].description | string | | | | servers[].variables | Record<string, string> | | | | outputFile | string | x | Name of the generated file. Supported file extensions are .json and .yaml | | functionNameRegexToInclude | string[] | | List of regex patters to include http functions based on their name | | functionNameRegexToExclude | string[] | | List of regex patters to exclude http functions based on their name | | excludeRequestBody | boolean | | Exclude the request body from the generated API definition | | excludeResponseBody | boolean | | Exclude the response body from the generated API definition |

Logic to include / exclude http functions:

  • If functionNameRegexToInclude and functionNameRegexToExclude are not specified all functions are used.
  • Otherwise:
    • If functionNameRegexToExclude is defined and the http function name matches some pattern from functionNameRegexToExclude, then the http function will be excluded from the api definition.
    • If functionNameRegexToInclude is defined and the http function name matches some pattern from functionNameRegexToInclude, then the http function will be included into the api definition.

Supported Features

  • URL path parameters
  • URL query parameters if requestQueryParamsValidation is used
  • Request body schema if requestBodyValidation is used
  • Response body schema if responseBodyValidation is used
  • Security schemas for bearer and function key authentication