登录
使用邮箱登录,获取其余接口所需的访问 Token。
POSThttps://www.mushroomproxies.com/api/SysLogin/Login
认证: 无需认证
参数
| 名称 | 位置 | 类型 | 必填 | 说明 |
|---|---|---|---|---|
| JSON 请求体 | string | 是 | 账号的邮箱地址。you@example.com | |
| appSecret | JSON 请求体 | string | 是 | 标识本站的应用密钥,可在控制台的开发者 API 页面复制。YOUR_APP_SECRET |
| loginType | JSON 请求体 | enum | 是 | pwd 为密码登录,code 为邮箱验证码登录。pwd |
| passWord | JSON 请求体 | string | 否 | loginType 为 pwd 时必填。YOUR_PASSWORD |
| verifyCode | JSON 请求体 | string | 否 | loginType 为 code 时必填。123456 |
请求示例
curl -X POST "https://www.mushroomproxies.com/api/SysLogin/Login" \
-H "Content-Type: application/json" \
-d '{"email":"you@example.com","appSecret":"YOUR_APP_SECRET","loginType":"pwd","passWord":"YOUR_PASSWORD"}'const response = await fetch("https://www.mushroomproxies.com/api/SysLogin/Login", {
method: "POST",
headers: {
"Content-Type": "application/json"
},
body: JSON.stringify({
"email": "you@example.com",
"appSecret": "YOUR_APP_SECRET",
"loginType": "pwd",
"passWord": "YOUR_PASSWORD"
}),
});
console.log(await response.json());import requests
response = requests.post(
"https://www.mushroomproxies.com/api/SysLogin/Login",
headers={
"Content-Type": "application/json"
},
json={
"email": "you@example.com",
"appSecret": "YOUR_APP_SECRET",
"loginType": "pwd",
"passWord": "YOUR_PASSWORD"
},
)
print(response.json())响应示例
{
"code": 200,
"message": "Success",
"body": {
"id": 1024,
"name": "developer",
"token": "YOUR_TOKEN"
}
}已精简,实际响应可能包含更多字段。