# 批量开/关企业版席位自动续费

> 全部文档的索引见 [llms.txt](https://ark.volcengine.com/llms.txt)；在任一文档页面地址后追加 `.md` 可获取该页的 Markdown 版本。

`POST https://ark.cn-beijing.volcengineapi.com/?Action=UpdateSeatAutoRenew&Version=2024-01-01`

企业版管理员批量设置企业版席位的自动续费状态。支持同时为多个席位开启或关闭自动续费，并采用部分成功语义返回处理结果。

> **注意**
>
> 本接口为部分成功语义：返回结果中 `SuccessIds` 与 `FailedResults` 分别列出更新成功与失败的席位，调用方需根据 `FailedResults` 自行重试或修复失败项。

## 鉴权

本接口支持鉴权方式如下，详情请参见 [Base URL 及鉴权](/docs/base-url-and-authentication)。

* Access Key 鉴权，请在 [Access Key 管理](https://console.volcengine.com/iam/keymanage) 页面，获取 Access Key。本接口仅支持 Access Key 鉴权。

---

<span id="request-parameters"></span>
## 请求参数

### Body 参数

**Plan** `string` `必选` | 商品名称

待设置自动续费状态的企业版商品名称。取值：

* `AgentPlanTeam`：Agent Plan 企业版
* `CodingPlanTeam`：Coding Plan 企业版

**SeatIds** `string[]` `必选` | 席位 ID 列表

待设置自动续费状态的席位 ID 列表。单次请求最多支持 200 个席位 ID，不允许传入空串或重复值。

**AutoRenew** `boolean` `必选` | 自动续费

是否开启自动续费。取值：

* `true`：开启自动续费
* `false`：关闭自动续费

**ProjectName** `string` `默认值 default` | 项目名称

席位所属的项目空间名称。未传值时使用默认项目。

## 响应参数

**SuccessIds** `string[]` | 成功席位 ID

本次操作中自动续费状态更新成功的席位 ID 列表。

**FailedResults** `object[]` | 失败席位明细

自动续费状态更新失败的明细列表，仅返回失败席位及其失败原因。

**SeatId** `string` | 失败席位 ID

`FailedResults.SeatId`

自动续费状态更新失败的席位 ID。

**Message** `string` | 失败原因

`FailedResults.Message`

自动续费状态更新失败的具体原因。


## 代码示例

## 默认

### cURL

#### Request

```bash
curl 'https://ark.cn-beijing.volcengineapi.com/?Action=UpdateSeatAutoRenew&Version=2024-01-01' \
  -H 'Content-Type: application/json' \
  -H 'X-Date: <X-Date>' \
  -H 'X-Content-Sha256: <X-Content-Sha256>' \
  -H 'Authorization: HMAC-SHA256 Credential=<AK>/<X-Date>/cn-beijing/ark/request, SignedHeaders=content-type;host;x-content-sha256;x-date, Signature=<Signature>' \
  -d '{
    "Plan": "AgentPlanTeam",
    "SeatIds": [
      "seat-agt-sm-001",
      "seat-agt-sm-002"
    ],
    "AutoRenew": true,
    "ProjectName": "default"
}
'
```

#### Response

```
{
  "ResponseMetadata": {
    "RequestId": "20260822094512A1B2C3D4E5F60708",
    "Action": "UpdateSeatAutoRenew",
    "Version": "2024-01-01",
    "Service": "ark",
    "Region": "cn-beijing"
  },
  "Result": {
    "SuccessIds": ["seat-agt-sm-001"],
    "FailedResults": [
      {
        "SeatId": "seat-agt-sm-002",
        "Message": "The seat status does not allow this operation."
      }
    ]
  }
}
```
