API 详情
Zepp Life(小米运动) 步数同步
Zepp Life(小米运动)登录并同步自定义步数。
ANY
API-KEY
分类:工具
限流 40 / 分钟
用量与额度
免费:日 50 / 月 1,500
超额 5 积分 / 次
当前积分 --
登录后可查看当前账号的用量与剩余额度。
免费额度用尽后才会扣除;未设置单价(0)则超额直接拒绝。
完整请求 URL
可直接在浏览器、终端或调试工具中调用
接口说明
Zepp Life / 小米运动 步数同步
使用华米(Zepp)开放登录与数据接口,将自定义步数同步到 Zepp Life(原小米运动)账号。
账号说明:必须为 Zepp Life 注册的手机号或邮箱及对应密码,不是小米账号。
请求
POST /api/tools/mi-motion-step(推荐,密码放 body)
也支持 GET 传参(不推荐,易出现在访问日志中)。
参数
| 参数 | 必填 | 说明 |
|---|---|---|
| user | 是 | 手机号(可带 +86)或邮箱 |
| password 或 pwd | 是 | Zepp Life 密码 |
| step | 否 | 指定步数(1–98800);不传则按下面规则随机 |
| min_step / max_step | 否 | 成对传入时在区间内随机 |
| time_curve | 否 | 未传 step 且未传 min_step/max_step 时:默认 1,按北京时间 0–22 点线性放大随机上限(同 mimotion);传 0 关闭则在 18000–25000 间随机 |
响应
code=200 时 data 含:account(脱敏)、steps、date、upstream(上游 message)。
在线调试
通过本站代发请求。GET 时会把 JSON 中的键值作为 Query,非 GET 时作为 JSON Body.
示例代码
提示:把 YOUR_API_KEY 替换为真实 API Key。
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
const payload = {
"step": "20000",
"user": "+8613800138000",
"password": "your_zepp_password"
};
const url = 'https://api.avrinbai.cn/api/tools/mi-motion-step';
const headers = {
"Accept": "application/json",
"Content-Type": "application/json",
"X-API-Key": "YOUR_API_KEY",
};
const res = await fetch(url, {
method: "ANY",
headers,
body: JSON.stringify(payload),
});
// 兼容返回 JSON / 纯文本 / 二进制
const contentType = res.headers.get("content-type") || "";
if (contentType.includes("application/json")) {
console.log(await res.json());
} else {
console.log(await res.text());
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
import axios from "axios";
const payload = {
"step": "20000",
"user": "+8613800138000",
"password": "your_zepp_password"
};
const headers = {
"Accept": "application/json",
"X-API-Key": "YOUR_API_KEY",
};
const url = "https://api.avrinbai.cn/api/tools/mi-motion-step";
const res = await axios.request({
url,
method: "ANY",
headers,
data: payload,
// responseType: "arraybuffer", // 若接口返回图片/音视频,可按需开启
});
console.log(res.status, res.data);
# ANY https://api.avrinbai.cn/api/tools/mi-motion-step
import requests
payload = {
"step": "20000",
"user": "+8613800138000",
"password": "your_zepp_password"
}
headers = {
"Accept": "application/json",
}
headers["X-API-Key"] = "YOUR_API_KEY"
res = requests.request(
"ANY",
"https://api.avrinbai.cn/api/tools/mi-motion-step",
headers=headers,
json=payload,
timeout=25,
)
print(res.status_code)
print(res.text)
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
payload := map[string]any{
"step": "20000",
"user": "+8613800138000",
"password": "your_zepp_password"
}
targetURL := "https://api.avrinbai.cn/api/tools/mi-motion-step"
b, _ := json.Marshal(payload)
body := bytes.NewReader(b)
req, _ := http.NewRequest("ANY", targetURL, body)
req.Header.Set("Accept", "application/json")
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
res, err := client.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
raw, _ := io.ReadAll(res.Body)
fmt.Println(res.StatusCode)
fmt.Println(string(raw))
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
payload := map[string]any{
"step": "20000",
"user": "+8613800138000",
"password": "your_zepp_password"
}
targetURL := "https://api.avrinbai.cn/api/tools/mi-motion-step"
b, _ := json.Marshal(payload)
body := bytes.NewReader(b)
req, _ := http.NewRequest("ANY", targetURL, body)
req.Header.Set("Accept", "application/json")
req.Header.Set("Content-Type", "application/json")
req.Header.Set("X-API-Key", "YOUR_API_KEY")
client := &http.Client{}
res, err := client.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
raw, _ := io.ReadAll(res.Body)
fmt.Println(res.StatusCode)
fmt.Println(string(raw))
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
import okhttp3.*;
public class Demo {
public static void main(String[] args) throws Exception {
OkHttpClient client = new OkHttpClient();
String payloadJson = {"step":"20000","user":"+8613800138000","password":"your_zepp_password"};
String url = "https://api.avrinbai.cn/api/tools/mi-motion-step";
RequestBody body = RequestBody.create(payloadJson, MediaType.parse("application/json"));
Request request = new Request.Builder()
.url(url)
.method("ANY", body)
.addHeader("Accept", "application/json")
.addHeader("Content-Type", "application/json")
.addHeader("X-API-Key", "YOUR_API_KEY")
.build();
try (Response response = client.newCall(request).execute()) {
System.out.println(response.code());
System.out.println(response.body() != null ? response.body().string() : "");
}
}
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
import okhttp3.*;
public class Demo {
public static void main(String[] args) throws Exception {
OkHttpClient client = new OkHttpClient();
String payloadJson = {"step":"20000","user":"+8613800138000","password":"your_zepp_password"};
String url = "https://api.avrinbai.cn/api/tools/mi-motion-step";
RequestBody body = RequestBody.create(payloadJson, MediaType.parse("application/json"));
Request request = new Request.Builder()
.url(url)
.method("ANY", body)
.addHeader("Accept", "application/json")
.addHeader("Content-Type", "application/json")
.addHeader("X-API-Key", "YOUR_API_KEY")
.build();
try (Response response = client.newCall(request).execute()) {
System.out.println(response.code());
System.out.println(response.body() != null ? response.body().string() : "");
}
}
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;
class Program
{
static async Task Main()
{
var payloadJson = {"step":"20000","user":"+8613800138000","password":"your_zepp_password"};
using var client = new HttpClient();
var url = "https://api.avrinbai.cn/api/tools/mi-motion-step";
using var request = new HttpRequestMessage(new HttpMethod("ANY"), url);
request.Headers.Add("Accept", "application/json");
request.Headers.Add("X-API-Key", "YOUR_API_KEY");
request.Content = new StringContent(payloadJson, Encoding.UTF8, "application/json");
using var response = await client.SendAsync(request);
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine((int)response.StatusCode);
Console.WriteLine(body);
}
}
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;
class Program
{
static async Task Main()
{
var payloadJson = {"step":"20000","user":"+8613800138000","password":"your_zepp_password"};
using var client = new HttpClient();
var url = "https://api.avrinbai.cn/api/tools/mi-motion-step";
using var request = new HttpRequestMessage(new HttpMethod("ANY"), url);
request.Headers.Add("Accept", "application/json");
request.Headers.Add("X-API-Key", "YOUR_API_KEY");
request.Content = new StringContent(payloadJson, Encoding.UTF8, "application/json");
using var response = await client.SendAsync(request);
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine((int)response.StatusCode);
Console.WriteLine(body);
}
}
<?php
// ANY https://api.avrinbai.cn/api/tools/mi-motion-step
$payload = json_decode('{\"step\":\"20000\",\"user\":\"+8613800138000\",\"password\":\"your_zepp_password\"}', true) ?: [];
$apiKey = 'YOUR_API_KEY';
$ch = curl_init();
if (in_array('ANY', ['GET', 'HEAD'], true)) {
$url = 'https://api.avrinbai.cn/api/tools/mi-motion-step' . (count($payload) ? ('?' . http_build_query($payload)) : '');
} else {
$url = 'https://api.avrinbai.cn/api/tools/mi-motion-step';
}
curl_setopt_array($ch, [
CURLOPT_URL => $url,
CURLOPT_CUSTOMREQUEST => 'ANY',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HEADER => true,
CURLOPT_TIMEOUT => 25,
]);
$headers = [
'Accept: application/json',
];
$headers[] = 'X-API-Key: ' . $apiKey;
if (! in_array('ANY', ['GET', 'HEAD'], true)) {
$body = json_encode($payload, JSON_UNESCAPED_UNICODE);
$headers[] = 'Content-Type: application/json';
curl_setopt($ch, CURLOPT_POSTFIELDS, $body);
}
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$raw = curl_exec($ch);
if ($raw === false) {
throw new RuntimeException('cURL error: ' . curl_error($ch));
}
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
$headerSize = curl_getinfo($ch, CURLINFO_HEADER_SIZE);
$rawHeaders = substr($raw, 0, $headerSize);
$rawBody = substr($raw, $headerSize);
curl_close($ch);
echo "HTTP {$status}\n";
echo $rawHeaders . "\n";
echo $rawBody;
curl -sS -X ANY \
-H "Content-Type: application/json" \
-H "X-API-Key: YOUR_API_KEY" \
"https://api.avrinbai.cn/api/tools/mi-motion-step" \
-d '{"step":"20000","user":"+8613800138000","password":"your_zepp_password"}'