Posting data and counting how much data

And you will have a proper api so you can do something like:
strapi.db.query('api::bid.bid').count({where: { product: productId l } })
To get count of bids