NGINX Status API

The Status API from NGINX — 1 operation(s) for status.

OpenAPI Specification

nginx-status-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: NGINX njs Scripting Connections Status API
  version: '0.8'
  description: The NGINX njs module provides a JavaScript runtime embedded inside NGINX. It does not expose HTTP endpoints itself. Instead, it offers scripting objects (HTTP request, stream session, Fetch API, etc.) that are available within njs handler functions configured in the NGINX configuration file. This specification documents the key njs objects as OpenAPI schemas only; the paths object is intentionally empty because there are no REST endpoints to describe.
  x-generated-from: documentation
  contact:
    name: NGINX
    url: https://nginx.org/en/docs/njs/reference.html
  license:
    name: BSD-2-Clause
    url: https://nginx.org/LICENSE
tags:
- name: Status
paths:
  /stub_status:
    get:
      operationId: getStubStatus
      summary: NGINX Retrieve Stub Status Metrics
      description: Returns plain-text status information including active connections, cumulative accepts/handled/requests counters, and current reading/writing/waiting connection counts.
      tags:
      - Status
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      responses:
        '200':
          description: Plain-text status output
          content:
            text/plain:
              schema:
                type: string
                description: 'Multi-line plain text. Line 1: "Active connections: <n>". Line 2: header "server accepts handled requests". Line 3: three space-separated integers (accepts, handled, requests). Line 4: "Reading: <n> Writing: <n> Waiting: <n>".'
                example: "Active connections: 291\nserver accepts handled requests\n 16630948 16630948 31070465\nReading: 6 Writing: 179 Waiting: 106"
              examples:
                getStubStatus200Example:
                  value: "Active connections: 291\nserver accepts handled requests\n 16630948 16630948 31070465\nReading: 6 Writing: 179 Waiting: 106"
                  x-microcks-default: true
externalDocs:
  description: NGINX njs Reference
  url: https://nginx.org/en/docs/njs/reference.html