lichess-org / api

Lichess API documentation and examples
https://lichess.org/api
GNU Affero General Public License v3.0
413 stars 140 forks source link

fixes BOT title in bots online endpoint #326

Closed jalpp closed 2 months ago

jalpp commented 3 months ago

fixes #243 task 3 adding bot user in Bot title and id containing bot in ID and user to make it easy to understand as previous response fields were confusing

tors42 commented 2 months ago

Edit, ooof, comment too late! :sweat_smile:

An alternative approach could be to add a new json file in example directory, and reference it as content example:

       content:
         application/x-ndjson:
           schema:
-            $ref: '../../schemas/BotUser.yaml'
+            $ref: '../../schemas/User.yaml'
+          example:
+            $ref: '../../example/user-georges-bot.json'

That way it is not needed to introduce the "duplicate" BotTitle.yaml and BotUser.yaml files.

(Note, the ../../example/user-georges-bot.json file does not yet exist, but would hold contents like:

{
    "id": "georges",
    "username": "Georges",
...
    "title": "BOT"
}