ruvnet/ruflo · error
itemIds array required
Error message
itemIds array required
What it means
The 'bulk-ratings' action found itemIds missing or not an array in body/query. Input guard: batch rating lookup requires a list of item ids to iterate; a scalar or absent value is rejected with 400 before the per-item GCS reads begin.
Source
Thrown at v3/@claude-flow/cli/cloud-functions/publish-registry/index.js:461
const ratings = JSON.parse(content.toString());
return res.json({
itemId,
average: Math.round(ratings.average * 10) / 10,
count: ratings.count,
// Don't expose individual user ratings
});
} catch {
return res.json({ itemId, average: 0, count: 0 });
}
}
case 'bulk-ratings': {
// Get ratings for multiple items at once
const { itemIds, itemType = 'plugin' } = req.body || req.query;
if (!itemIds || !Array.isArray(itemIds)) {
return res.status(400).json({ error: 'itemIds array required' });
}
const results = {};
for (const itemId of itemIds.slice(0, 50)) { // Limit to 50 items
try {
const ratingsFile = bucket.file(`ratings/${itemType}/${itemId}.json`);
const [exists] = await ratingsFile.exists();
if (exists) {
const [content] = await ratingsFile.download();
const ratings = JSON.parse(content.toString());
results[itemId] = {
average: Math.round(ratings.average * 10) / 10,
count: ratings.count,
};
} else {
results[itemId] = { average: 0, count: 0 };View on GitHub (pinned to fa13ee4ad6)
Solutions
- Provide all required parameters listed in the message.
- Validate required fields before dispatch and report the full set of missing fields at once.
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at v3/@claude-flow/cli/cloud-functions/publish-registry/index.js:461 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of ruvnet/ruflo@fa13ee4ad6 (2026-08-18).
Data as JSON: /api/errors/4f9b2b53490e1a3b.
Report an issue: GitHub.