feat: add New API channel support
This commit is contained in:
@@ -271,11 +271,10 @@ func testChannel(ctx context.Context, channel *model.Channel, testUserID int, te
|
||||
|
||||
apiType, _ := common.ChannelType2APIType(channel.Type)
|
||||
if info.RelayMode == relayconstant.RelayModeResponsesCompact &&
|
||||
apiType != constant.APITypeOpenAI &&
|
||||
apiType != constant.APITypeCodex {
|
||||
!common.IsResponsesCompactAPIType(apiType) {
|
||||
return testResult{
|
||||
context: c,
|
||||
localErr: fmt.Errorf("responses compaction test only supports openai/codex channels, got api type %d", apiType),
|
||||
localErr: fmt.Errorf("responses compaction test is not supported for api type %d", apiType),
|
||||
newAPIError: types.NewError(fmt.Errorf("unsupported api type: %d", apiType), types.ErrorCodeInvalidApiType),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user