openapi: 3.0.3 info: title: NRDP (Nagios Remote Data Processor) API description: | NRDP is a PHP-based passive result collector for Nagios. It accepts host and service check results and external commands over HTTP POST in either XML or JSON form, then injects them into Nagios Core via the external command pipe. Authentication uses a token configured in `config.inc.php`. version: '2.0.x' contact: name: Nagios Enterprises url: https://github.com/NagiosEnterprises/nrdp servers: - url: https://{nrdpHost}/nrdp description: Self-hosted NRDP collector. variables: nrdpHost: default: nagios.example.com security: - TokenForm: [] tags: - name: Submission description: Submit passive check results and external commands. paths: /: post: tags: [Submission] summary: Submit NRDP Payload description: | Submit a `checkresults` payload (`cmd=submitcheck`) or a Nagios external command (`cmd=submitcmd`). The body can be `application/x-www-form-urlencoded` with an XML/JSON `XMLDATA`/`JSONDATA` field. operationId: submitNrdp requestBody: required: true content: application/x-www-form-urlencoded: schema: type: object required: [token, cmd] properties: token: { type: string, description: NRDP authentication token. } cmd: type: string enum: [submitcheck, submitcmd] XMLDATA: type: string description: | XML payload, root `` containing one or more `` elements with ``, ``, ``, `` children. JSONDATA: type: string description: | JSON string equivalent of XMLDATA — e.g. `{"checkresults":[{"checkresult":{"type":"service",...}}]}`. command: type: string description: External command string when `cmd=submitcmd`. responses: '200': description: Submission result. content: application/json: schema: { $ref: '#/components/schemas/NrdpResponse' } components: securitySchemes: TokenForm: type: apiKey in: query name: token schemas: NrdpResponse: type: object properties: status: { type: integer, description: 0 on success, non-zero on error. } message: { type: string } meta: type: object properties: output: { type: string }