Skip to main content

Show HN: A thin Python library to access HN data using Algolia's API https://ift.tt/30FAKmg

Show HN: A thin Python library to access HN data using Algolia's API Hello community. Some time ago I was trying to create a project for my students using Hacker News data. As you might know, HN offers an official API [0], but it's based on Firebase and I felt it's main usage is to build clients, rather than consult data. I found out that Algolia also provides an official REST API [1]. It's exactly what I needed: the ability to "search" HN. Either by keywords, type of stories (Show HN, Ask HN, etc) and/or date. So I created a thin python wrapper on top of Algolia's Search API: https://ift.tt/2Z4ngQG The library is in early stage, but already usable. A few examples: How to search posts from one user: results = search_by_date( author='pg', hits_per_page=1000) How to search posts by type (this would find this same post) results = search_by_date( 'thin python library', show_hn=True, hits_per_page=1000) I'm working on implementing the the other methods. If you have suggestions please bring them up! [0] https://ift.tt/1s98Sn3 [1] https://ift.tt/1eaWICc July 20, 2019 at 04:14AM

Comments

Popular posts from this blog

Launch HN: Simmer (YC W19) – Reviews for Delivery Dishes https://ift.tt/2Y4sD67

Launch HN: Simmer (YC W19) – Reviews for Delivery Dishes Hi HackerNews community! We’re Vaibhav and Richard, founders of Simmer ( https://usesimmer.com ). Simmer aggregates dishes from DoorDash, Caviar, GrubHub, and basically every other delivery platform out there, and tells users the best dishes across the board. We do this by providing dish-level reviews. Users find highly reviewed dishes on Simmer, choose the delivery platform of their liking, and we deep link them into their chosen delivery app. We essentially lead gen to delivery. We started working on Simmer because we loved trying new restaurants, but never knew what to order. Especially, when there’s a 5 page menu. We always asked ourselves, “Why aren’t there ratings for individual dishes?” We launched our app with this restaurant-centric use case (reviews for every dish at every restaurant), but when we rolled out delivery integrations, we realized that users resonated most with the delivery angle. They found it particularly ...