- API
- BanHistory 封禁历史
- ClientDiscovery 客户端发现
- Snapshot 快照记录
- UserApplication 用户应用程序
- User 用户
- Github OAuth2 登录GET
- BTN兼容客户端协议通讯
提交 Peers
开发中
GET
/ping/peers/submit
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Body 参数application/json
populate_time
integer
数据生成时间
peers
array[object (BTN Peer) {13}]
必需
ip_address
string
IP 地址
peer_port
integer
Peer 端口号
peer_id
string
Peer ID
client_name
string
客户端名称
torrent_identifier
string
种子识别码
torrent_size
integer
种子大小
downloaded
integer
从 Peer 下载的数据量
rt_download_speed
integer
从 Peer 下载的速率
uploaded
integer
向 Peer 上传的数据量
rt_upload_speed
integer
向 Peer 上传的速率
peer_progress
number
Peer 汇报进度
downloader_progress
integer
用户下载器进度
peer_flag
string
uTP Flags
示例
{
"populate_time": 1713971696000,
"peers": [
{
"ip_address": "CE67:2B6F:646A:138B:9E4F:DD47:894E:608E",
"peer_port": 12345,
"peer_id": "-BC1234-",
"client_name": "BitComet 1.2.3.4",
"torrent_identifier": "<使用特定算法对 info_hash 进行加盐哈希>",
"torrent_size": 12346789765,
"downloaded": 3463465,
"rt_download_speed": 133525,
"uploaded": 2345754,
"rt_upload_speed": 234456465,
"peer_progress": 0.1245,
"downloader_progress": 1,
"peer_flag": "u I H X E P"
},
{
"ip_address": "198.148.143.87",
"peer_port": 23333,
"peer_id": "-qB2312-",
"client_name": "qBittorrent 2.3.1.2",
"torrent_identifier": "<使用特定算法对 info_hash 进行加盐哈希>",
"torrent_size": 12346789765,
"downloaded": 3463465,
"rt_download_speed": 133525,
"uploaded": 2345754,
"rt_upload_speed": 234456465,
"peer_progress": 0.1245,
"downloader_progress": 1,
"peer_flag": "u I H X E P"
}
]
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://btn-prod.ghostchu-services.top/ping/peers/submit' \
--header 'Content-Type: application/json' \
--data-raw '{
"populate_time": 1713971696000,
"peers": [{
"ip_address": "CE67:2B6F:646A:138B:9E4F:DD47:894E:608E",
"peer_port": 12345,
"peer_id": "-BC1234-",
"client_name": "BitComet 1.2.3.4",
"torrent_identifier": "<使用特定算法对 info_hash 进行加盐哈希>",
"torrent_size": 12346789765,
"downloaded": 3463465,
"rt_download_speed": 133525,
"uploaded": 2345754,
"rt_upload_speed": 234456465,
"peer_progress": 0.1245,
"downloader_progress": 1,
"peer_flag": "u I H X E P"
},
{
"ip_address": "198.148.143.87",
"peer_port": 23333,
"peer_id": "-qB2312-",
"client_name": "qBittorrent 2.3.1.2",
"torrent_identifier": "<使用特定算法对 info_hash 进行加盐哈希>",
"torrent_size": 12346789765,
"downloaded": 3463465,
"rt_download_speed": 133525,
"uploaded": 2345754,
"rt_upload_speed": 234456465,
"peer_progress": 0.1245,
"downloader_progress": 1,
"peer_flag": "u I H X E P"
}
]
}'
返回响应
🟢200成功
text/plain
Body
object {0}
示例
修改于 2024-08-17 18:57:18