# 快速开始

5 分钟跑通第一个住宅代理请求。

## 1. 创建子账号

1. 进入[控制台](https://dashboard.helodata.com) → **住宅 → 子账号**。
2. 点击 **创建子账号**，命名（例如 `acme1`），并设置密码。
3. 控制台会分配一个形如 `s1a2b3c4d5e` 的子账号名。把名称与密码都复制下来。

## 2. 拼装用户名

最简形态——任意美国住宅 IP——的代理用户名为：

```
helo_s1a2b3c4d5e-type-res-region-us
```

把示例中的 `s1a2b3c4d5e` 替换为你的真实子账号名。完整可用字段见[用户名格式](/helodata-zh/kuai-su-ru-men/username-format.md)。

## 3. 发送请求

### curl

```bash
curl -x http://helo_s1a2b3c4d5e-type-res-region-us:PASSWORD@gate.helodata.io:7777 \
     https://ipv4.icanhazip.com
```

### Python (requests)

```python
import requests

USER = "helo_s1a2b3c4d5e-type-res-region-us"
PASS = "PASSWORD"
proxy = f"http://{USER}:{PASS}@gate.helodata.io:7777"

r = requests.get(
    "https://ipv4.icanhazip.com",
    proxies={"http": proxy, "https": proxy},
    timeout=30,
)
print(r.text.strip())
```

### Node.js (undici)

```js
import { fetch, ProxyAgent } from "undici";

const user = "helo_s1a2b3c4d5e-type-res-region-us";
const pass = "PASSWORD";
const agent = new ProxyAgent(`http://${user}:${pass}@gate.helodata.io:7777`);

const res = await fetch("https://ipv4.icanhazip.com", { dispatcher: agent });
console.log((await res.text()).trim());
```

返回的应该是一个美国住宅 IP，而不是你本机的 IP。

## 4. 常见进阶

| 目标            | 在用户名上追加                        |
| ------------- | ------------------------------ |
| 指向德国          | 把 `-region-us` 改为 `-region-de` |
| 下钻到加州洛杉矶      | 追加 `-state-ca-city-la`         |
| 保持同一 IP 10 分钟 | 追加 `-session-job1-sesstime-10` |
| 绑定特定 ISP      | 追加 `-asn-7922`（示例：Comcast）     |

可自由组合，但字段顺序固定，详见[用户名格式](/helodata-zh/kuai-su-ru-men/username-format.md)。

## 5. 第一次请求排错

* **407 Proxy Authentication Required** — 用户名或密码错误，或来源 IP 未加入白名单。详见 [407](/helodata-zh/gu-zhang-pai-cha/407.md)。
* **522 Connection timed out** — 上游 IP 不可达，重试即可。详见 [522](/helodata-zh/gu-zhang-pai-cha/522.md)。
* **SSL 握手错误** — 客户端可能需要更新 CA 证书。详见 [SSL/TLS 错误](/helodata-zh/gu-zhang-pai-cha/ssl-errors.md)。

## 下一步

* [身份认证](/helodata-zh/chan-pin/overview/authentication.md) — 在无凭证存储环境下改用 IP 白名单
* [会话与轮换](/helodata-zh/chan-pin/overview/sessions-and-rotation.md) — 粘性 vs 轮换策略
* [集成指南](/helodata-zh/ji-cheng-zhi-nan/integrations.md) — Selenium、Puppeteer、Scrapy、反检测浏览器


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.helodata.com/helodata-zh/chan-pin/overview/quick-start.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
