mirror of
https://github.com/pi-hole/FTL.git
synced 2024-10-26 16:52:18 +02:00
@@ -11,6 +11,99 @@ components:
|
||||
description: |
|
||||
This API hook returns content from the log of the embedded DNS resolver `dnsmasq`.
|
||||
|
||||
Every successful request will return a `nextID`.
|
||||
This ID can be used on the next request to only get lines which were added *after* the last request.
|
||||
This makes periodic polling for new log lines easy as no check for duplicated log lines is necessary.
|
||||
The expected behavior for an immediate re-request of a log line with the same ID is an empty response.
|
||||
As soon as the next message arrived, this will be included in your request and `nextID` is incremented by one.
|
||||
parameters:
|
||||
- $ref: 'logs.yaml#/components/parameters/logs/dnsmasq/nextID'
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/log'
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/nextID'
|
||||
'401':
|
||||
description: Unauthorized
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: 'common.yaml#/components/errors/unauthorized'
|
||||
ftl:
|
||||
get:
|
||||
summary: Get DNS log content
|
||||
tags:
|
||||
- "FTL information"
|
||||
operationId: "get_dns_log"
|
||||
description: |
|
||||
This API hook returns content from the log of FTL.
|
||||
|
||||
Every successful request will return a `nextID`.
|
||||
This ID can be used on the next request to only get lines which were added *after* the last request.
|
||||
This makes periodic polling for new log lines easy as no check for duplicated log lines is necessary.
|
||||
The expected behavior for an immediate re-request of a log line with the same ID is an empty response.
|
||||
As soon as the next message arrived, this will be included in your request and `nextID` is incremented by one.
|
||||
parameters:
|
||||
- $ref: 'logs.yaml#/components/parameters/logs/dnsmasq/nextID'
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/log'
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/nextID'
|
||||
'401':
|
||||
description: Unauthorized
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: 'common.yaml#/components/errors/unauthorized'
|
||||
http:
|
||||
get:
|
||||
summary: Get DNS log content
|
||||
tags:
|
||||
- "FTL information"
|
||||
operationId: "get_dns_log"
|
||||
description: |
|
||||
This API hook returns content from the log of the embedded CivetWeb HTTP server.
|
||||
|
||||
Every successful request will return a `nextID`.
|
||||
This ID can be used on the next request to only get lines which were added *after* the last request.
|
||||
This makes periodic polling for new log lines easy as no check for duplicated log lines is necessary.
|
||||
The expected behavior for an immediate re-request of a log line with the same ID is an empty response.
|
||||
As soon as the next message arrived, this will be included in your request and `nextID` is incremented by one.
|
||||
parameters:
|
||||
- $ref: 'logs.yaml#/components/parameters/logs/dnsmasq/nextID'
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/log'
|
||||
- $ref: 'logs.yaml#/components/schemas/logs/dnsmasq/nextID'
|
||||
'401':
|
||||
description: Unauthorized
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: 'common.yaml#/components/errors/unauthorized'
|
||||
ph7:
|
||||
get:
|
||||
summary: Get DNS log content
|
||||
tags:
|
||||
- "FTL information"
|
||||
operationId: "get_dns_log"
|
||||
description: |
|
||||
This API hook returns content from the log of the embedded PH7 engine.
|
||||
|
||||
Every successful request will return a `nextID`.
|
||||
This ID can be used on the next request to only get lines which were added *after* the last request.
|
||||
This makes periodic polling for new log lines easy as no check for duplicated log lines is necessary.
|
||||
|
||||
@@ -153,6 +153,15 @@ paths:
|
||||
/logs/dnsmasq:
|
||||
$ref: 'logs.yaml#/components/paths/logs/dnsmasq'
|
||||
|
||||
/logs/ftl:
|
||||
$ref: 'logs.yaml#/components/paths/logs/ftl'
|
||||
|
||||
/logs/http:
|
||||
$ref: 'logs.yaml#/components/paths/logs/http'
|
||||
|
||||
/logs/ph7:
|
||||
$ref: 'logs.yaml#/components/paths/logs/ph7'
|
||||
|
||||
/endpoints:
|
||||
$ref: 'endpoints.yaml#/components/paths/endpoints'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user