NGINX · Schema

Ngx

The ngx global object (since 0.5.0). Provides NGINX runtime information and the fetch() method.

API GatewayCachingCloud-NativeLoad BalancerOpen-SourceReverse ProxyWeb Server

Properties

Name Type Description
build string Optional NGINX build name (since 0.8.0).
conf_file_path string File path to the current NGINX configuration file (since 0.8.0).
conf_prefix string NGINX configuration prefix directory (since 0.7.8).
error_log_path string File path to the current error log file (since 0.8.0).
prefix string NGINX installation prefix.
version string NGINX version string.
version_number integer NGINX version as a number.
worker_id integer Current worker process ID.
View JSON Schema on GitHub

JSON Schema

njs-ngx-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/nginx/refs/heads/main/json-schema/njs-ngx-schema.json",
  "title": "Ngx",
  "description": "The ngx global object (since 0.5.0). Provides NGINX runtime information and the fetch() method.",
  "type": "object",
  "properties": {
    "build": {
      "type": "string",
      "readOnly": true,
      "description": "Optional NGINX build name (since 0.8.0).",
      "example": "nginx-plus-r32"
    },
    "conf_file_path": {
      "type": "string",
      "readOnly": true,
      "description": "File path to the current NGINX configuration file (since 0.8.0).",
      "example": "/etc/nginx/nginx.conf"
    },
    "conf_prefix": {
      "type": "string",
      "readOnly": true,
      "description": "NGINX configuration prefix directory (since 0.7.8).",
      "example": "/etc/nginx/"
    },
    "error_log_path": {
      "type": "string",
      "readOnly": true,
      "description": "File path to the current error log file (since 0.8.0).",
      "example": "/var/log/nginx/error.log"
    },
    "prefix": {
      "type": "string",
      "readOnly": true,
      "description": "NGINX installation prefix.",
      "example": "/usr/local/nginx"
    },
    "version": {
      "type": "string",
      "readOnly": true,
      "description": "NGINX version string.",
      "example": "1.25.3"
    },
    "version_number": {
      "type": "integer",
      "readOnly": true,
      "description": "NGINX version as a number.",
      "example": 1025003
    },
    "worker_id": {
      "type": "integer",
      "readOnly": true,
      "description": "Current worker process ID.",
      "example": 0
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/njs-ngx"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.