> For the complete documentation index, see [llms.txt](https://scx.gitbook.io/sc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://scx.gitbook.io/sc/scp-docs/api-wen-dang/ding-yue-guan-li.md).

# 订阅管理

节点配置管理

## 获取订阅列表

> 返回当前用户的所有节点订阅。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}},"schemas":{"APIResponse":{"properties":{"code":{"description":"0 表示成功；其他值表示业务错误码。","type":"integer"},"data":{"description":"返回载荷；成功时存在，部分错误会包含结构化详情。"},"message":{"type":"string"}},"type":"object"},"Profile":{"properties":{"created_at":{"format":"date-time","type":"string"},"is_active":{"type":"boolean"},"name":{"type":"string"},"updated_at":{"format":"date-time","type":"string"},"url":{"type":"string"},"user_id":{"format":"int64","type":"integer"},"uuid":{"format":"uuid","type":"string"}},"type":"object"}}},"paths":{"/api/v1/profiles":{"get":{"description":"返回当前用户的所有节点订阅。","responses":{"200":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/APIResponse"},{"properties":{"data":{"items":{"$ref":"#/components/schemas/Profile"},"type":"array"}},"type":"object"}]}}},"description":"订阅列表。"},"401":{"description":"API Key 无效。"},"403":{"description":"未启用 API 访问能力。"}},"summary":"获取订阅列表","tags":["订阅管理"]}}}}
```

## 创建节点订阅

> 创建新的节点订阅。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}},"schemas":{"APIResponse":{"properties":{"code":{"description":"0 表示成功；其他值表示业务错误码。","type":"integer"},"data":{"description":"返回载荷；成功时存在，部分错误会包含结构化详情。"},"message":{"type":"string"}},"type":"object"},"Profile":{"properties":{"created_at":{"format":"date-time","type":"string"},"is_active":{"type":"boolean"},"name":{"type":"string"},"updated_at":{"format":"date-time","type":"string"},"url":{"type":"string"},"user_id":{"format":"int64","type":"integer"},"uuid":{"format":"uuid","type":"string"}},"type":"object"}}},"paths":{"/api/v1/profiles":{"post":{"description":"创建新的节点订阅。","requestBody":{"content":{"application/json":{"schema":{"properties":{"name":{"maxLength":16,"minLength":1,"pattern":"^[^ \\t]+$","type":"string"},"url":{"description":"订阅链接或者节点 URL。","format":"uri","maxLength":2048,"type":"string"}},"required":["name","url"],"type":"object"}}},"required":true},"responses":{"201":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/APIResponse"},{"properties":{"data":{"$ref":"#/components/schemas/Profile"}},"type":"object"}]}}},"description":"节点订阅已创建。"},"400":{"description":"请求参数无效。"},"401":{"description":"API Key 无效。"},"429":{"description":"请求过于频繁，请稍后再试。"}},"summary":"创建节点订阅","tags":["订阅管理"]}}}}
```

## 获取节点订阅配置限额

> 返回当前用户的订阅配置容量。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}},"schemas":{"APIResponse":{"properties":{"code":{"description":"0 表示成功；其他值表示业务错误码。","type":"integer"},"data":{"description":"返回载荷；成功时存在，部分错误会包含结构化详情。"},"message":{"type":"string"}},"type":"object"},"ProfileConfigQuotaDTO":{"description":"当前用户的节点订阅配置容量。","properties":{"current_count":{"description":"当前用户拥有的未删除订阅配置数量，包括已停用配置。","format":"int64","minimum":0,"type":"integer"},"max_count":{"description":"最大订阅数量。无限额或未启用订阅管理时为 0。","format":"int64","minimum":0,"type":"integer"},"profile_management_enabled":{"description":"订阅管理功能是否可用。","type":"boolean"},"remaining_count":{"description":"还可添加的配置数量。无限额或未启用订阅管理时为 0。","format":"int64","minimum":0,"type":"integer"},"unlimited":{"description":"是否已启用订阅管理且有效配置限额为无限。","type":"boolean"}},"required":["max_count","current_count","remaining_count","unlimited","profile_management_enabled"],"type":"object"}}},"paths":{"/api/v1/profiles/quota":{"get":{"description":"返回当前用户的订阅配置容量。","responses":{"200":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/APIResponse"},{"properties":{"data":{"$ref":"#/components/schemas/ProfileConfigQuotaDTO"}},"type":"object"}]}}},"description":"订阅配置限额。"},"401":{"description":"API Key 无效。"},"403":{"description":"未启用 API 访问能力。"},"500":{"description":"服务器内部错误。"},"503":{"description":"服务器内部错误。"},"504":{"description":"服务器内部错误。"}},"summary":"获取节点订阅配置限额","tags":["订阅管理"]}}}}
```

## 获取节点订阅详情

> 按 UUID 返回单个节点订阅。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}},"schemas":{"APIResponse":{"properties":{"code":{"description":"0 表示成功；其他值表示业务错误码。","type":"integer"},"data":{"description":"返回载荷；成功时存在，部分错误会包含结构化详情。"},"message":{"type":"string"}},"type":"object"},"Profile":{"properties":{"created_at":{"format":"date-time","type":"string"},"is_active":{"type":"boolean"},"name":{"type":"string"},"updated_at":{"format":"date-time","type":"string"},"url":{"type":"string"},"user_id":{"format":"int64","type":"integer"},"uuid":{"format":"uuid","type":"string"}},"type":"object"}}},"paths":{"/api/v1/profiles/{uuid}":{"get":{"description":"按 UUID 返回单个节点订阅。","parameters":[{"in":"path","name":"uuid","required":true,"schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/APIResponse"},{"properties":{"data":{"$ref":"#/components/schemas/Profile"}},"type":"object"}]}}},"description":"节点订阅详情。"},"401":{"description":"API Key 无效。"},"404":{"description":"未找到。"}},"summary":"获取节点订阅详情","tags":["订阅管理"]}}}}
```

## 更新节点订阅

> 更新节点订阅。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}},"schemas":{"APIResponse":{"properties":{"code":{"description":"0 表示成功；其他值表示业务错误码。","type":"integer"},"data":{"description":"返回载荷；成功时存在，部分错误会包含结构化详情。"},"message":{"type":"string"}},"type":"object"},"Profile":{"properties":{"created_at":{"format":"date-time","type":"string"},"is_active":{"type":"boolean"},"name":{"type":"string"},"updated_at":{"format":"date-time","type":"string"},"url":{"type":"string"},"user_id":{"format":"int64","type":"integer"},"uuid":{"format":"uuid","type":"string"}},"type":"object"}}},"paths":{"/api/v1/profiles/{uuid}":{"put":{"description":"更新节点订阅。","parameters":[{"in":"path","name":"uuid","required":true,"schema":{"format":"uuid","type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"properties":{"is_active":{"type":"boolean"},"name":{"maxLength":16,"minLength":1,"pattern":"^[^ \\t]+$","type":"string"},"url":{"format":"uri","maxLength":2048,"type":"string"}},"type":"object"}}}},"responses":{"200":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/APIResponse"},{"properties":{"data":{"$ref":"#/components/schemas/Profile"}},"type":"object"}]}}},"description":"节点订阅已更新。"},"401":{"description":"API Key 无效。"},"404":{"description":"未找到。"},"429":{"description":"请求过于频繁，请稍后再试。"}},"summary":"更新节点订阅","tags":["订阅管理"]}}}}
```

## 删除节点订阅

> 删除一个节点订阅。

```json
{"openapi":"3.0.3","info":{"title":"SpeedCentre+ 用户 API","version":"1.0"},"tags":[{"description":"节点配置管理","name":"订阅管理"}],"servers":[{"description":"用户 API 服务","url":"https://api.speedcentre.plus"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"description":"API Key。","in":"header","name":"X-Api-Key","type":"apiKey"}}},"paths":{"/api/v1/profiles/{uuid}":{"delete":{"description":"删除一个节点订阅。","parameters":[{"in":"path","name":"uuid","required":true,"schema":{"format":"uuid","type":"string"}}],"responses":{"200":{"description":"节点订阅已删除。"},"401":{"description":"API Key 无效。"},"404":{"description":"未找到。"},"429":{"description":"请求过于频繁，请稍后再试。"}},"summary":"删除节点订阅","tags":["订阅管理"]}}}}
```
