Getting no overload matches this call in bool query


I am getting this no overload matches error in bool query . For single term it works fine: const searchResult = await client.search({
index: 'articles',
body: {
query: {
terms: {
articleId: articleIds // Using terms query to match any of the articleIds
}
}
}
}); but as soon its more than one, this error comes up