---
title: "PUT /v1/admin/source-channels/by-source/{sourceId}"
method: PUT
path: "/v1/admin/source-channels/by-source/{sourceId}"
tags: ["ChannelAdminService"]
---

# PUT /v1/admin/source-channels/by-source/{sourceId}

`PUT /v1/admin/source-channels/by-source/{sourceId}`

SetSourceChannelBindings 整批替换某资源下绑定的渠道集合（含选举排序）。
 strict_model_mapping 渠道映射未覆盖资源全部模型时 400（SOURCE_BINDING_MODEL_UNSUPPORTED）。

## Path parameters

- `sourceId` string, required

## Request body

- ChannelV1SetSourceChannelBindingsRequest
  - `entries` ChannelV1SourceChannelEntry[]
    - `channelId` string
    - `priority` integer
    - `weight` integer — weight 同 priority 组内的加权分配比重；0 = 不参与加权、仅兜底排在组末。 建议默认 1；负值返回 400。
  - `sourceId` string

## Response `200`

OK

- ChannelV1SetSourceChannelBindingsReply
  - `items` ChannelV1SourceChannelBindingInfo[]
    - `channelId` string
    - `channelName` string
    - `channelStatus` integer
    - `channelType` string
    - `priority` integer
    - `sourceCode` string
    - `sourceId` string
    - `sourceName` string
    - `weight` integer — weight 同 priority 组内的加权分配比重；0 = 不参与加权、仅兜底排在组末。

---

[API](https://skmtc.dev/apiqik/apis/apiqik-api.md) · [All operations](https://skmtc.dev/apiqik/apis/apiqik-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/apiqik/apiqik-api/revisions/e06b96127408/schema)
