> For the complete documentation index, see [llms.txt](https://loyalproxy.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://loyalproxy.gitbook.io/docs/documentation/zh-hans/dong-tai-zhu-zhai-ip/can-shu-shuo-ming.md).

# 参数说明

{% hint style="warning" %}
**使用须知**：LoyalProxy 全系代理产品均需在海外网络环境下运行，请确保您已自行配置好相应的海外网络环境。
{% endhint %}

本文展示如何使用 `curl` 通过 LoyalProxy 动态住宅代理 IP 发起请求，适用于终端或脚本中直接调用代理连接。

#### 参数格式

```yaml
<账户名>-<代理类型>-<定位信息>[-sid-<会话ID>]
```

#### 参数说明

<table data-header-hidden data-search="false"><thead><tr><th width="156.2000732421875"></th><th width="124"></th><th width="128.4000244140625"></th><th></th></tr></thead><tbody><tr><td>名称</td><td>类型</td><td>是否必备</td><td>备注</td></tr><tr><td><code>account</code></td><td>string</td><td>是</td><td>账户名</td></tr><tr><td><code>proxyAdress</code></td><td>string</td><td>是</td><td>代理地址</td></tr><tr><td><code>country</code></td><td>string</td><td>否</td><td>国家</td></tr><tr><td><code>state</code></td><td>string</td><td>否</td><td>省份</td></tr><tr><td><code>city</code></td><td>string</td><td>否</td><td>城市</td></tr><tr><td><code>session</code></td><td>string</td><td>否</td><td>会话ID，最长支持 11 位字符</td></tr><tr><td><code>sessTime</code></td><td>int64</td><td>否</td><td>预设 5 分钟，可选 1-180 分钟</td></tr><tr><td><code>sessFallBack</code></td><td>int64</td><td>否</td><td>下线时，是否补充节点</td></tr></tbody></table>

#### 定位格式

<table data-header-hidden><thead><tr><th width="133"></th><th width="230.39990234375"></th><th width="129"></th><th></th></tr></thead><tbody><tr><td>级别</td><td>格式</td><td>代理类型写法</td><td>示例</td></tr><tr><td>无定位</td><td><code>any</code></td><td><code>res</code></td><td><code>account-res-any</code></td></tr><tr><td>国家</td><td><code>&#x3C;country></code></td><td><code>res</code></td><td><code>account-res-us</code></td></tr><tr><td>国家+州</td><td><code>&#x3C;country>_&#x3C;state></code></td><td><code>res_sc</code></td><td><code>account-res_sc-us_california</code></td></tr><tr><td>国家+州+城市</td><td><code>&#x3C;country>_&#x3C;state>_&#x3C;city></code></td><td><code>res_sc</code></td><td><code>account-res_sc-us_california_losangeles</code></td></tr></tbody></table>

> **说明：**
>
> * **当定位信息包含州或城市时，代理类型必须添加 `sc` 后缀（如 `res_sc`）**
> * **所有地区名称需使用小写字母，且不含空格，例如：`us`、`california`、`losangeles`、`newsouthwales`**

#### 请求示例

以下示例中，请将 `account`、`password`、`[ip]`、`[port]` 替换为您实际获取的代理信息。

**1. 随机节点（无定位）**

```shell
# 不固定节点（每次请求自动更换 IP）
curl -x http://account-res-any:password@[ip]:[port] http://httpbin.org/ip

# 固定节点（通过 sid 保持同一 IP）
curl -x http://account-res-any-sid-295592634:password@[ip]:[port] http://httpbin.org/ip
```

**2. 指定国家**

```shell
# 不固定节点
curl -x http://account-res-us:password@[ip]:[port] http://httpbin.org/ip

# 固定节点
curl -x http://account-res-us-sid-295592634:password@[ip]:[port] http://httpbin.org/ip
```

**3. 指定国家-地区（需使用 socks5 协议及 res\_sc 类型）**

```shell
# 不固定节点
curl -x socks5://account-res_sc-us_california:password@[ip]:[port] http://httpbin.org/ip

# 固定节点
curl -x socks5://account-res_sc-us_california-sid-295592634:password@[ip]:[port] http://httpbin.org/ip
```

**4. 指定国家-地区-城市（需使用 res\_sc 类型）**

```shell
# 不固定节点
curl -x http://account-res_sc-us_california_losangeles:password@[ip]:[port] http://httpbin.org/ip

# 固定节点
curl -x http://account-res_sc-us_california_losangeles-sid-295592634:password@[ip]:[port] http://httpbin.org/ip
```
