Skip to content

Commit 24eaa5e

Browse files
committed
Fix query provider model url
1 parent 1cad46b commit 24eaa5e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

service/provider_service.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ async def get_models(self, *, db: AsyncSession, pk: int) -> list[GetAIProviderMo
4444
ai_provider = await self.get(db=db, pk=pk)
4545
if ai_provider.type not in {AIProviderType.openai, AIProviderType.xai, AIProviderType.openrouter}:
4646
raise errors.RequestError(msg='当前供应商暂不支持自动同步模型,请手动维护模型列表')
47-
url = f'{ai_provider.api_host}/models'
47+
url = f'{ai_provider.api_host}/v1/models'
4848
headers = {'Authorization': f'Bearer {ai_provider.api_key}'}
4949
async with httpx.AsyncClient(timeout=10) as client:
5050
try:

0 commit comments

Comments
 (0)