{"record":{"id":"ff4763349a9842bd","repo":"Radarr/Radarr","slug":"ids-must-be-provided-ff4763","errorCode":null,"errorMessage":"ids must be provided","messagePattern":"ids must be provided","errorType":"http","errorClass":"BadRequestException","httpStatus":400,"severity":"error","filePath":"src/Radarr.Api.V3/ProviderControllerBase.cs","lineNumber":134,"sourceCode":"                Test(providerDefinition, true);\n            }\n\n            if (hasDefinitionChanged)\n            {\n                _providerFactory.Update(providerDefinition);\n            }\n\n            return Accepted(existingDefinition.Id);\n        }\n\n        [HttpPut(\"bulk\")]\n        [Consumes(\"application/json\")]\n        [Produces(\"application/json\")]\n        public virtual ActionResult<TProviderResource> UpdateProvider([FromBody] TBulkProviderResource providerResource)\n        {\n            if (!providerResource.Ids.Any())\n            {\n                throw new BadRequestException(\"ids must be provided\");\n            }\n\n            var definitionsToUpdate = _providerFactory.Get(providerResource.Ids).ToList();\n\n            foreach (var definition in definitionsToUpdate)\n            {\n                _providerFactory.SetProviderCharacteristics(definition);\n\n                if (providerResource.Tags != null)\n                {\n                    var newTags = providerResource.Tags;\n                    var applyTags = providerResource.ApplyTags;\n\n                    switch (applyTags)\n                    {\n                        case ApplyTags.Add:\n                            newTags.ForEach(t => definition.Tags.Add(t));\n                            break;","sourceCodeStart":116,"sourceCodeEnd":152,"githubUrl":"https://github.com/Radarr/Radarr/blob/ca451608dc60c6cec754aba8d96bfa30e9468ed5/src/Radarr.Api.V3/ProviderControllerBase.cs#L116-L152","documentation":"Thrown by the generic PUT .../bulk endpoint on ProviderControllerBase (the base for indexers, download clients, notifications, etc.) when the bulk provider resource's Ids collection is empty. A bulk update needs target provider ids to apply changes to, so an empty set is a bad request.","triggerScenarios":"A PUT to /api/v3/{provider}/bulk (e.g. indexer, downloadClient, notification) with a body whose Ids list is empty.","commonSituations":"A bulk tag-edit action in the UI invoked with no providers selected; a script applying tag changes to an empty filtered list; a client sending an empty ids array.","solutions":["Include at least one provider id in the Ids array of the bulk request body.","Disable bulk-edit controls in the UI until at least one provider row is selected."],"exampleFix":"// before\nPUT /api/v3/indexer/bulk\n{ \"ids\": [], \"tags\": [2], \"applyTags\": \"add\" }\n// after\nPUT /api/v3/indexer/bulk\n{ \"ids\": [1, 4], \"tags\": [2], \"applyTags\": \"add\" }","handlingStrategy":"validation","validationCode":"if (providerResource.Ids is null || !providerResource.Ids.Any()) {\n    return BadRequest(\"Select at least one provider id for the bulk update.\");\n}","typeGuard":"static bool HasIds<T>(T bulk) where T : IBulkProviderResource\n    => bulk?.Ids?.Any() == true;","tryCatchPattern":null,"preventionTips":["Require at least one provider selected before enabling bulk edit.","Short-circuit empty bulk payloads in API clients before sending."],"tags":["api","validation","provider","bulk","bad-request"],"backgroundTag":null,"analyzedSha":"ca451608dc60c6cec754aba8d96bfa30e9468ed5","analyzedAt":"2026-08-13T17:21:54.115Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}