source: TFP-WebServer/WebServer/src/WebAPI/APIs/Log.openapi.yaml@ 474

Last change on this file since 474 was 471, checked in by alloc, 15 months ago

Fixed: Possibly multiple parsing of query string

File size: 3.1 KB
RevLine 
[460]1openapi: 3.1.0
2info:
3 title: Log
4 version: '1'
5
6components:
7 schemas:
8 LogEntry:
9 type: object
[467]10 properties:
11 id:
12 type: integer
13 minimum: 0
14 description: Consecutive ID/number of this log line
[460]15 msg:
16 type: string
17 examples:
18 - 'Version: Alpha 21 (b48) Compatibility Version: Alpha 21, Build: WindowsPlayer 64 Bit'
19 description: Message
20 type:
21 type: string
22 enum:
23 - Error
24 - Assert
25 - Warning
26 - Log
27 - Exception
28 description: Severity type
29 trace:
30 type: string
31 description: Stacktrace if entry is an Exception
32 isotime:
33 type: string
34 format: date-time
35 uptime:
36 type: string
37 examples:
38 - '87123'
[467]39 description: Time since server was started in milliseconds
[460]40 required:
[467]41 - id
[460]42 - msg
43 - type
44 - trace
45 - isotime
46 - uptime
47
48 LogData:
49 type: object
50 properties:
51 entries:
52 type: array
53 items:
54 $ref: '#/components/schemas/LogEntry'
55 firstLine:
56 type: integer
57 examples:
58 - 47
59 description: Number of first line retrieved
60 lastLine:
61 type: integer
62 examples:
63 - 48
64 description: Number of next line to retrieve to follow up without missing entries
65 required:
66 - entries
67 - firstLine
68 - lastLine
69
70
71 parameters:
72 LogCountParameter:
73 name: count
74 in: query
75 required: false
76 schema:
77 type: integer
78 description: Number of lines to fetch. If negative fetches count lines from the firstLine. Defaults to 50.
79
80 LogFirstLineParameter:
81 name: firstLine
82 in: query
83 required: false
84 schema:
85 type: integer
86 description: First line number to fetch. Defaults to the oldest stored log line if count is positive. Defaults to the most recent log line if count is negative.
87
88paths:
[471]89 /api/log:
[460]90 get:
91 tags:
92 - Log
93 summary: Log
94 description: Get an amount of lines from the server log
95 operationId: log.get
96 parameters:
97 - $ref: '#/components/parameters/LogCountParameter'
98 - $ref: '#/components/parameters/LogFirstLineParameter'
99 responses:
100 200:
101 description: Log information
102 content:
103 application/json:
104 schema:
105 type: object
106 properties:
107 data:
108 $ref: '#/components/schemas/LogData'
109 meta:
110 $ref: './openapi.yaml#/components/schemas/ResultEnvelopeMeta'
111 required:
112 - data
113 - meta
114 403:
115 $ref: './openapi.yaml#/components/responses/Unauthorized'
116 security:
117 - apiTokenName: []
118 apiTokenSecret: []
119 - sessionCookie: []
Note: See TracBrowser for help on using the repository browser.