Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> So here’s the approach I ended up using, which worked much better: request each post by its ID. That’s right, instead of asking for posts in batches of 100, we’re going to need to ask for each post individually by its post ID. We’ll do the same for comments.

Seems a bit over the top imho. Maybe a better approach is to ask for a 1,000 and look for any missing — which you can grab individually.

I’d be a little annoyed at people not using batch mode and making so many request but that’s just me.



Each request still returns 100 posts. It's just that you have to specify the 100 post IDs individually.

Their default listing mode works very poorly. It would certainly be more requests to use a hybrid system like you're talking about.


I thought the same at first but a bit further on it turns out to still batch them, you can apparently specify multiple IDs by comma-separating them.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: