Skip to content

Commit dce92f6

Browse files
committed
Update README
1 parent 3a2127f commit dce92f6

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

README.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,4 +147,44 @@ Content-Type: application/json
147147
"code": 0,
148148
"message": "修改个人信息成功"
149149
}
150+
```
151+
## 添加地点接口
152+
153+
接口地址:/addlocation
154+
155+
请求方法:POST
156+
157+
请求参数:
158+
- token:用户登录后生成的令牌,类型为字符串
159+
- name:地点名称,类型为字符串
160+
- description:地点描述,类型为字符串
161+
162+
请求示例:
163+
```
164+
POST /addlocation
165+
Content-Type: application/json
166+
167+
{
168+
"token": "abcd1234",
169+
"name": "New Location",
170+
"description": "This is a new location"
171+
}
172+
```
173+
174+
返回数据:
175+
- code:返回状态码,0 表示成功,非0 表示失败
176+
- message:返回信息,添加地点成功或失败的提示信息
177+
- data:返回的数据,添加成功后返回新创建的地点信息
178+
179+
返回示例:
180+
```
181+
{
182+
"code": 0,
183+
"message": "添加地点成功",
184+
"data": {
185+
"id": 1,
186+
"name": "New Location",
187+
"description": "This is a new location"
188+
}
189+
}
150190
```

0 commit comments

Comments
 (0)