> For the complete documentation index, see [llms.txt](https://docs.ipwo.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ipwo.net/kai-fa-zhe-wen-dang/chang-jian-cuo-wu/api-fan-hui-wei-kong.md).

# API 返回为空

如果请求代理后出现：

```
返回为空
无数据
Empty Response
```

通常表示：

```
请求未正常获取目标内容
```

***

### 一、常见原因

#### 1. 请求超时

目标网站响应过慢，可能导致：

```
请求提前结束
```

建议增加 timeout 时间。

***

#### cURL 示例

```bash
curl --max-time 30 \
-x http://us.ipwo.net:7878 \
-U username_custom_zone_us:password \
http://ipinfo.io
```

***

#### 2. 目标网站拦截

部分网站会检测：

* IP 频率
* User-Agent
* 浏览器指纹

导致返回：

```
空白内容
```

***

#### 3. IP 被风控

高频请求可能导致：

* 无返回
* 验证页面
* 空响应

建议：

* 降低请求频率
* 使用粘性 Session
* 更换 IP

***

#### 4. 请求未真正走代理

建议先测试：

```bash
curl -x http://us.ipwo.net:7878 -U username_custom_zone_us:password http://ipinfo.io
```

确认 IP 是否已切换。

***

#### 5. HTTPS / SSL 问题

部分环境可能出现：

```
SSL 握手失败
```

建议检查：

* HTTPS 配置
* SSL 证书
* requests/curl 参数

***

### 二、推荐排查方式

建议按顺序检查：

```
1. curl 测试代理
↓
2. 检查 IP 是否变化
↓
3. 增加 timeout
↓
4. 降低请求频率
↓
5. 更换 IP 或 Session
```

***

### 三、推荐开发建议

推荐：

* 增加 Retry 重试
* 增加 timeout
* 使用海外 VPS
* 使用真实浏览器 UA

避免：

* 高频并发请求
* 多账号共用 IP

***

### 四、相关文章

* [超时 Timeout](/kai-fa-zhe-wen-dang/chang-jian-cuo-wu/chao-shi-timeout.md)
* [IP 不生效](/kai-fa-zhe-wen-dang/chang-jian-cuo-wu/ip-bu-sheng-xiao.md)
* [代理连接失败](/kai-fa-zhe-wen-dang/chang-jian-cuo-wu/dai-li-lian-jie-shi-bai.md)
* [如何检测代理是否生效](/dai-li-jian-ce-yu-yin-si-an-quan/ru-he-jian-ce-dai-li-shi-fou-sheng-xiao.md)
* [如何降低封禁风险](/dai-li-ji-chu-zhi-shi/ru-he-jiang-di-feng-jin-feng-xian.md)
* [API 调用与批量采集](/dai-li-ji-chu-zhi-shi/api-diao-yong-yu-pi-liang-cai-ji.md)
