# 400 错误请求：需要 API 版本头部

- **ID:** `api/rest-api-version-header-required`
- **领域:** api
- **类别:** config_error
- **验证级别:** ai_generated
- **修复率:** 92%

## 根因

API 端点需要特定的版本头部（例如 Accept-Version 或 X-API-Version），但请求中未包含。

## 版本兼容性

| 版本 | 状态 | 引入 | 弃用 |
|------|------|------|------|
| REST API v1.0 | active | — | — |
| Stripe API v2023-10 | active | — | — |
| GitHub API v3 | active | — | — |

## 解决方案

1. ```
   Add the required version header to every request.
   ```
2. ```
   Use an API client configuration that automatically includes the version header.
   ```

## 无效尝试

- **** — The API specifically checks the header; query parameters are ignored for versioning. (80% 失败率)
- **** — Some APIs require explicit versioning; no default is assumed. (90% 失败率)
- **** — The version check is often middleware-level and applies to all methods. (95% 失败率)
