[460] | 1 | openapi: 3.1.0
|
---|
[459] | 2 | info:
|
---|
| 3 | title: 7 Days To Die WebAPI
|
---|
[460] | 4 | version: '1.0.0'
|
---|
[459] | 5 | servers:
|
---|
| 6 | - url: /
|
---|
| 7 |
|
---|
| 8 | components:
|
---|
| 9 | schemas:
|
---|
| 10 | ResultEnvelopeMeta:
|
---|
| 11 | type: object
|
---|
| 12 | properties:
|
---|
| 13 | serverTime:
|
---|
| 14 | type: string
|
---|
| 15 | format: date-time
|
---|
| 16 | requestMethod:
|
---|
| 17 | type: string
|
---|
| 18 | examples:
|
---|
| 19 | - GET
|
---|
| 20 | - POST
|
---|
| 21 | requestSubpath:
|
---|
| 22 | type: string
|
---|
| 23 | examples:
|
---|
| 24 | - search
|
---|
| 25 | description: >-
|
---|
| 26 | URL path (without query arguments) starting from after the API name,
|
---|
| 27 | excluding the initial slash '/'
|
---|
| 28 | requestBody:
|
---|
| 29 | type:
|
---|
| 30 | - object
|
---|
| 31 | - 'null'
|
---|
| 32 | examples:
|
---|
| 33 | - id: a
|
---|
| 34 | filter: 123
|
---|
| 35 | description: If erroneous request had a valid JSON body it is included here
|
---|
| 36 | errorCode:
|
---|
| 37 | type: string
|
---|
| 38 | examples:
|
---|
| 39 | - GET_WITH_BODY
|
---|
| 40 | - INVALID_COMMAND
|
---|
| 41 | description: Custom error identifier
|
---|
| 42 | exceptionMessage:
|
---|
| 43 | type: string
|
---|
| 44 | description: Message (If API execution threw an exception)
|
---|
| 45 | exceptionTrace:
|
---|
| 46 | type: string
|
---|
| 47 | description: Stack trace (If API execution threw an exception)
|
---|
| 48 | required:
|
---|
| 49 | - serverTime
|
---|
| 50 | - requestMethod
|
---|
| 51 | - requestSubpath
|
---|
| 52 | - requestBody
|
---|
| 53 | - errorCode
|
---|
| 54 |
|
---|
| 55 | TypeEntityId:
|
---|
| 56 | type: integer
|
---|
| 57 | minimum: 0
|
---|
| 58 | examples:
|
---|
| 59 | - 171
|
---|
| 60 | description: World-unique EntityID
|
---|
| 61 |
|
---|
| 62 | TypeVector3i:
|
---|
| 63 | type: object
|
---|
| 64 | properties:
|
---|
| 65 | x:
|
---|
| 66 | type: integer
|
---|
| 67 | examples:
|
---|
| 68 | - -123
|
---|
| 69 | y:
|
---|
| 70 | type: integer
|
---|
| 71 | examples:
|
---|
| 72 | - 61
|
---|
| 73 | z:
|
---|
| 74 | type: integer
|
---|
| 75 | examples:
|
---|
| 76 | - 734
|
---|
| 77 | required:
|
---|
| 78 | - x
|
---|
| 79 | - 'y'
|
---|
| 80 | - z
|
---|
| 81 | description: 3D vector in full blocks
|
---|
| 82 |
|
---|
[460] | 83 | TypeUserIdString:
|
---|
| 84 | type: string
|
---|
| 85 | pattern: '^\[a-zA-Z]+_[\w]+$'
|
---|
| 86 | examples:
|
---|
| 87 | - 'Steam_76561198021925107'
|
---|
| 88 | description: User ID including platform
|
---|
[459] | 89 |
|
---|
[460] | 90 | TypeUserIdObject:
|
---|
| 91 | anyOf:
|
---|
| 92 | - type: object
|
---|
| 93 | properties:
|
---|
| 94 | combinedString:
|
---|
| 95 | $ref: '#/components/schemas/TypeUserIdString'
|
---|
| 96 | platformId:
|
---|
| 97 | type: string
|
---|
| 98 | examples:
|
---|
| 99 | - Steam
|
---|
| 100 | - XBL
|
---|
| 101 | description: Gaming platform the ID references
|
---|
| 102 | userId:
|
---|
| 103 | type: string
|
---|
| 104 | examples:
|
---|
| 105 | - '76561198021925107'
|
---|
| 106 | description: Unique ID of the user within the given gaming platform
|
---|
| 107 | required:
|
---|
| 108 | - combinedString
|
---|
| 109 | - platformId
|
---|
| 110 | - userId
|
---|
| 111 | description: User ID
|
---|
| 112 | - type: 'null'
|
---|
[463] | 113 |
|
---|
| 114 | TypeGameTimeObject:
|
---|
| 115 | type: object
|
---|
| 116 | properties:
|
---|
| 117 | days:
|
---|
| 118 | type: integer
|
---|
| 119 | minimum: 1
|
---|
| 120 | hours:
|
---|
| 121 | type: integer
|
---|
| 122 | minimum: 0
|
---|
| 123 | maximum: 23
|
---|
| 124 | minutes:
|
---|
| 125 | type: integer
|
---|
| 126 | minimum: 0
|
---|
| 127 | maximum: 59
|
---|
| 128 | required:
|
---|
| 129 | - days
|
---|
| 130 | - hours
|
---|
| 131 | - minutes
|
---|
| 132 |
|
---|
[460] | 133 |
|
---|
[462] | 134 | parameters:
|
---|
| 135 | UserIdPathParameter:
|
---|
| 136 | name: id
|
---|
| 137 | in: path
|
---|
| 138 | required: true
|
---|
| 139 | schema:
|
---|
| 140 | $ref: '#/components/schemas/TypeUserIdString'
|
---|
| 141 |
|
---|
| 142 |
|
---|
[459] | 143 | responses:
|
---|
| 144 | HttpEmptyEnvelopedResponse:
|
---|
| 145 | description: Empty result
|
---|
| 146 | content:
|
---|
| 147 | application/json:
|
---|
| 148 | schema:
|
---|
| 149 | type: object
|
---|
| 150 | properties:
|
---|
| 151 | data:
|
---|
| 152 | type: array
|
---|
| 153 | items:
|
---|
| 154 | type: 'null'
|
---|
| 155 | maxItems: 0
|
---|
| 156 | examples:
|
---|
| 157 | - []
|
---|
| 158 | meta:
|
---|
| 159 | $ref: '#/components/schemas/ResultEnvelopeMeta'
|
---|
| 160 | required:
|
---|
| 161 | - data
|
---|
| 162 | - meta
|
---|
| 163 |
|
---|
| 164 | Unauthorized:
|
---|
| 165 | description: Not authorized to call this operation
|
---|
| 166 |
|
---|
| 167 |
|
---|
| 168 | securitySchemes:
|
---|
| 169 | apiTokenName:
|
---|
| 170 | type: apiKey
|
---|
| 171 | in: header
|
---|
| 172 | name: X-SDTD-API-TOKENNAME
|
---|
| 173 | description: Authentication by a "WebToken" with token name and token secret, passed in as header fields. This specifies the token name.
|
---|
| 174 | apiTokenSecret:
|
---|
| 175 | type: apiKey
|
---|
| 176 | in: header
|
---|
| 177 | name: X-SDTD-API-SECRET
|
---|
| 178 | description: Authentication by a "WebToken" with token name and token secret, passed in as header fields. This specifies the token secret.
|
---|
| 179 | sessionCookie:
|
---|
| 180 | type: apiKey
|
---|
| 181 | in: cookie
|
---|
| 182 | name: sid
|
---|
| 183 | description: Authentication by session cookie. A cookie can be received from the session endpoints.
|
---|
| 184 |
|
---|
| 185 |
|
---|
| 186 | paths:
|
---|