Live data from Hacker News

Geddit: Open-source, Reddit client for Android without using API

github.com

11–20 of 146 posts

Re: Geddit: Open-source, Reddit client for Android without using API

#11
post #2

Neat. I wasn't aware that there's an endpoint you could use to retrieve JSON data without an API key. If this project were to gain more traction, I suppose they would interfere with that, right? It's sad to see that every free Reddit client is forced to be a browser nowadays.

> Neat. I wasn't aware that there's an endpoint you could use to retrieve JSON data without an API key. Call me naive but in fact I always thought that's what the apps were using. One thing that took me by surprise in the whole fiasco was that the apps were actually using their own API keys -- I always thought I was just logged in to reddit in my own account. I figured it might be using some backend service for stori…

Based on folks using ReVanced to patch the shut down apps, it's an oauth client id that was specific to an app. Communication was with reddit's API directly.

Re: Geddit: Open-source, Reddit client for Android without using API

#12
post #6
post #2

Neat. I wasn't aware that there's an endpoint you could use to retrieve JSON data without an API key. If this project were to gain more traction, I suppose they would interfere with that, right? It's sad to see that every free Reddit client is forced to be a browser nowadays.

The JSON endpoints are pretty neat, you can just take any reddit page, be it subreddit, submission comments or username, and append `/.json` to the URL and tadaa , JSON data. Although like you said, I'm pretty sure they will axe it at some point, and I'm honestly surprised that they didn't already. I can imagine however, that old.reddit.com scraping/parsing layers will pop up left and right as soon as that happens (a…

There is also `/.rss`.

Re: Geddit: Open-source, Reddit client for Android without using API

#15
post #14

Is this Capacitor specific code? Here it seems the JS code can fetch data from any domain: https://github.com/kaangiray26/geddit-app/blob/main/src/js/g... Since that is not possible in the browser, is that something Capacitor provides?

you can always fetch data from any domain, iff that server sets the correct CORS headers, unless I'm misunderstanding.

https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS

Re: Geddit: Open-source, Reddit client for Android without using API

#17
post #15
post #14

Is this Capacitor specific code? Here it seems the JS code can fetch data from any domain: https://github.com/kaangiray26/geddit-app/blob/main/src/js/g... Since that is not possible in the browser, is that something Capacitor provides?

you can always fetch data from any domain, iff that server sets the correct CORS headers, unless I'm misunderstanding. https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS

Most servers don't set a CORS header though.

So usually it does not work in the browser.

Try this in your console while not on Reddit:

    fetch('https://www.reddit.com/.json')

Re: Geddit: Open-source, Reddit client for Android without using API

#19
post #7

Call me cynical but building a client for a user hostile service is a sign of a Stockholm syndrome.

I totally agree. Also, this is a thankless task. The app will break every other week when they change webpage (if it's using web scraping) or when they change their internal API because the client was updated. (if it's using the reversed-engineered official app's API)
Post reply on HN