{"record":{"id":"5306f63ef7d4b834","repo":"BerriAI/litellm","slug":"team-not-found-passed-team-id-team-id-5306f6","errorCode":null,"errorMessage":"Team not found, passed team id: {team_id}.","messagePattern":"Team not found, passed team id: (.+?)\\.","errorType":"http","errorClass":"HTTPException","httpStatus":404,"severity":"error","filePath":"litellm/proxy/management_endpoints/team_endpoints.py","lineNumber":4145,"sourceCode":"                detail={\n                    \"error\": \"Database not connected. Connect a database to your proxy - https://docs.litellm.ai/docs/simple_proxy#managing-auth---virtual-keys\"\n                },\n            )\n        if team_id is None:\n            raise HTTPException(\n                status_code=status.HTTP_422_UNPROCESSABLE_ENTITY,\n                detail={\"message\": \"Malformed request. No team id passed in.\"},\n            )\n\n        try:\n            team_info: BaseModel | None = await _team_db(prisma_client).find_unique(\n                where={\"team_id\": team_id},\n                include={\"litellm_model_table\": True, \"object_permission\": True},\n            )\n            if team_info is None:\n                raise Exception\n        except Exception:\n            raise HTTPException(\n                status_code=status.HTTP_404_NOT_FOUND,\n                detail={\"message\": f\"Team not found, passed team id: {team_id}.\"},\n            )\n        await validate_membership(\n            user_api_key_dict=user_api_key_dict,\n            team_table=LiteLLM_TeamTable.model_validate(team_info.model_dump()),\n        )\n\n        ## GET ALL KEYS ##\n        keys = await prisma_client.get_data(\n            team_id=team_id,\n            table_name=\"key\",\n            query_type=\"find_all\",\n            expires=datetime.now(),\n            limit=key_limit,\n        )\n\n        if keys is None:","sourceCodeStart":4127,"sourceCodeEnd":4163,"githubUrl":"https://github.com/BerriAI/litellm/blob/77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8/litellm/proxy/management_endpoints/team_endpoints.py#L4127-L4163","documentation":"Error \"Team not found, passed team id: {team_id}.\" thrown in BerriAI/litellm.","triggerScenarios":"Thrown at litellm/proxy/management_endpoints/team_endpoints.py:4145 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the team id exists via /team/list or /team/info before calling this endpoint."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8","analyzedAt":"2026-08-18T11:44:31.656Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}