update api docs

This commit is contained in:
nikk gitanes
2024-04-14 03:52:41 +03:00
parent 3cd9f5ef90
commit 3a037c88d8
8 changed files with 44 additions and 41 deletions

View File

@@ -393,7 +393,7 @@ paths:
- text/html
responses:
"200":
description: Magnet links
description: HTML with Magnet links
summary: Get HTML of magnet links
tags:
- Pages
@@ -527,7 +527,7 @@ paths:
- application/json
description: Allow to get or set server settings.
parameters:
- description: Settings request
- description: 'Settings request. Available params for action: get, set, def'
in: body
name: request
required: true
@@ -537,7 +537,7 @@ paths:
- application/json
responses:
"200":
description: Depends on what action has been asked
description: Settings JSON or nothing. Depends on what action has been asked.
schema:
$ref: '#/definitions/settings.BTSets'
summary: Get / Set server settings
@@ -554,13 +554,13 @@ paths:
- API
/stat:
get:
description: Stat server.
description: Show server and torrents statistics.
produces:
- text/plain
responses:
"200":
description: Stats
summary: Stat server
description: TorrServer statistics
summary: TorrServer Statistics
tags:
- Pages
/stream:
@@ -658,17 +658,19 @@ paths:
description: Torrent status
schema:
$ref: '#/definitions/state.TorrentStatus'
summary: Only one file support
summary: Add .torrent file
tags:
- API
/torrents:
post:
consumes:
- application/json
description: Allow to add, get or set torrents to server. The action depends
of what has been asked.
description: Allow to list, add, remove, get, set, drop, wipe torrents on server.
The action depends of what has been asked.
parameters:
- description: Torrent request
- description: 'Torrent request. Available params for action: add, get, set,
rem, list, drop, wipe. link required for add, hash required for get, set,
rem, drop.'
in: body
name: request
required: true
@@ -688,7 +690,8 @@ paths:
- application/json
description: Allow to set, list or remove viewed torrents from server.
parameters:
- description: Viewed torrent request
- description: 'Viewed torrent request. Available params for action: set, rem,
list'
in: body
name: request
required: true