{"record":{"id":"e8bfdf550e17e619","repo":"Mintplex-Labs/anything-llm","slug":"no-valid-fields-to-update","errorCode":null,"errorMessage":"No valid fields to update.","messagePattern":"No valid fields to update\\.","errorType":"http","errorClass":null,"httpStatus":400,"severity":"error","filePath":"server/endpoints/modelRouter.js","lineNumber":82,"sourceCode":"        if (error) return response.status(400).json({ router, error });\n        await Telemetry.sendTelemetry(\"model_router_created\");\n        return response.status(200).json({ router });\n      } catch (e) {\n        console.error(e);\n        response.sendStatus(500);\n      }\n    }\n  );\n\n  app.put(\n    \"/model-routers/:id\",\n    [validatedRequest, flexUserRoleValid([ROLES.admin])],\n    async (request, response) => {\n      try {\n        const { id } = request.params;\n        const data = reqBody(request);\n        const { router, error } = await ModelRouter.update(Number(id), data);\n        if (error) return response.status(400).json({ router, error });\n        ModelRouterService.invalidateRouter(Number(id));\n        return response.status(200).json({ router });\n      } catch (e) {\n        console.error(e);\n        response.sendStatus(500);\n      }\n    }\n  );\n\n  app.delete(\n    \"/model-routers/:id\",\n    [validatedRequest, flexUserRoleValid([ROLES.admin])],\n    async (request, response) => {\n      try {\n        const { id } = request.params;\n        const success = await ModelRouter.delete(Number(id));\n        if (!success)\n          return response","sourceCodeStart":64,"sourceCodeEnd":100,"githubUrl":"https://github.com/Mintplex-Labs/anything-llm/blob/3aec848f2885144aa8f1e53b9731a04310d5d558/server/endpoints/modelRouter.js#L64-L100","documentation":"Validation error from ModelRouter.update relayed by PUT /model-routers/:id: none of the submitted fields were recognized/updatable properties, so there is nothing to change and the update is rejected rather than performing a no-op.","triggerScenarios":"Thrown at server/endpoints/modelRouter.js:82 when the library encounters an invalid state.","commonSituations":"Router update request contained no recognized fields.","solutions":["Include at least one updatable field in the request body.","Check field names against the router update schema."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3aec848f2885144aa8f1e53b9731a04310d5d558","analyzedAt":"2026-08-18T10:02:21.017Z","contentChangedAt":"2026-08-18T10:02:21.017Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}