# 绑定下行域名 (/products/mikustream/mikustream-live-domain-api/5-mikustream-live-bind-downstream-domain-api)



最近更新时间: 2025-11-20 22:47:49

# 描述 [#描述]

为指定直播空间绑定下行域名（播放域名）

# 接口信息 [#接口信息]

* **请求方法**: `POST`
* **请求地址**: `<bucket>`.mls.cn-east-1.qiniumiku.com
* **请求路径**: `/`

# 请求参数 [#请求参数]

## Query 参数 [#query-参数]

| 参数名称   |   类型   |  必填 | 示例值    | 描述   |
| :----- | :----: | :-: | :----- | :--- |
| domain | string |  是  | domain | 域名配置 |

## Header 参数 [#header-参数]

\| 参数名称 | 类型 | 必填 | 示例值 | 描述 |
\|:---|:---:|:---:|:---:|:---|:---|
\| Host | string | 是 | `&lt;bucket&gt;`.mls.cn-east-1.qiniumiku.com | 请求的服务域名 |
\| Authorization | string | 是 | `&lt;QiniuToken&gt;` | 管理凭证 QiniuToken，[生成规则](/products/mikustream/3-mikustream-live-http-requests-authentication) |

## Body 参数 (application/json) [#body-参数-applicationjson]

示例：

```json
{
    "domain":"www.example.com",
    "type":"liveRtmp"
}
```

## 参数 [#参数]

| 参数名称   |   类型   | 是否必需 | 说明                                                                                                                                     |
| :----- | :----: | :--: | :------------------------------------------------------------------------------------------------------------------------------------- |
| domain | string |  必需  | 要绑定的域名                                                                                                                                 |
| type   | string |  可选  | 域名类型（liveRtmp：rtmp 播放域名; liveHls：hls 播放域名; liveDash：dash 播放域名; liveFlv：flv 播放域名; whep：whep 播放域名; live：所有的播放协议共用一个域名; liveSrt：srt 播放域名） |

# 请求示例 [#请求示例]

```http
POST /?domain HTTP/1.1
Host: test.mls.cn-east-1.qiniumiku.com
Authorization: <QiniuToken>
Content-Type: application/json

{
    "domain":"www.example.com",
    "type":"liveRtmp"
}
```

# 返回响应 [#返回响应]

## 响应状态码 [#响应状态码]

* **请查阅**: [这里](/products/mikustream/4-mikustream-live-error-code)

## 响应示例 [#响应示例]

```json
{
    "domain": "www.example.com",
    "cname": "www.example.com.subscribe.mikudns.com",
    "creationDate": "2019-01-01T00:00:00.000+08:00",
    "lastModified": "2019-01-01T00:00:00.000+08:00",
    "connectId": "QXV0aG9yaXphdGlvbg",
    "type": "liveRtmp"
}
```

## 响应参数 [#响应参数]

| 参数名称         |   类型   | 说明                                                                                                                                   |
| :----------- | :----: | :----------------------------------------------------------------------------------------------------------------------------------- |
| domain       | string | 域名                                                                                                                                   |
| cname        | string | CNAME 域名别名                                                                                                                           |
| creationDate | string | 创建时间，遵循 ISO 8601 格式                                                                                                                  |
| lastModified | string | 修改时间，遵循 ISO 8601 格式                                                                                                                  |
| connectId    | string | 连接 id                                                                                                                                |
| type         | string | 域名类型（liveRtmp：rtmp 播放域名; liveHls：hls 播放域名; liveDash：dash 播放域名; liveFlv：flv 播放域名; whep：whep 播放域名；liveSrt：srt 播放域名；live：所有的播放协议共用一个域名） |
