Skip to content

Commit

Permalink
Merge pull request #29 from n-WN/master
Browse files Browse the repository at this point in the history
Update Traffic-Stats-API.zh.md
  • Loading branch information
tobyxdd authored Jul 23, 2024
2 parents 2d028ee + c3f74bc commit b98ca66
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions docs/docs/advanced/Traffic-Stats-API.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Traffic Stats API

If an API secret is set in your configuration, you will need to add the `Authorization` header when making a request.

Example:

```shell
curl -H 'Authorization: secret' http://ip:port/path
```

### GET `/traffic`

This endpoint returns a JSON map of client IDs to their traffic statistics.
Expand Down
8 changes: 8 additions & 0 deletions docs/docs/advanced/Traffic-Stats-API.zh.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# 流量统计 API

如果配置中设置了 API secret,调用时需要在请求头加上 `Authorization` 标头。

请求:

```shell
curl -H 'Authorization: secret' http://ip:port/path
```

### GET `/traffic`

此接口返回一个 JSON map,是每个用户的流量信息。
Expand Down

0 comments on commit b98ca66

Please sign in to comment.