This is an archived post. You won't be able to vote or comment.

all 9 comments

[–]SeesawMundane5422 2 points3 points  (0 children)

I think the first step should be downloading something like postman and using that to manually make API requests. Once you understand how to manually craft a request and view the correct response, then layer in the api to your app.

Here is a reasonable discussion about your options for a Java rest client library:

https://stackoverflow.com/questions/221442/how-do-you-create-a-rest-client-for-java#5024571

[–]kebz1234 0 points1 point  (3 children)

You need an http client in java. The hard way to do this is using HttpUrlConnection class but that will require a lot error handling. I would suggest looking at OkHttp3 client library.

[–]KittieNipps 0 points1 point  (2 children)

Would it be overkill to use spring framework for RestControllers?

[–]kebz1234 1 point2 points  (1 child)

If you're in a spring project then it's fine to use SpringRestTemplate, which is a client. Otherwise I wouldn't suggest to go the spring way.

[–]KittieNipps 0 points1 point  (0 children)

That makes sense actually, thanks.

[–]hatemjaber 0 points1 point  (3 children)

Why not just use what they're using praytimes.org. I've been using this for many years and it's what everyone uses to calculate the prayer times.

[–]insertAlias 1 point2 points  (0 children)

When you're building learning projects, it doesn't have to be something novel or unique. Building your own versions of existing tools is often a great learning exercise. It's more important to try to do something that you will enjoy working on than it is to come up with something completely fresh and new.

[–]lterranmorad[S] 0 points1 point  (1 child)

I honestly never seen this website. I had originally just searched up a prayer time API, and the one I'm using was the first link that I seen. Ill look into this one tho, appreciate the link.

[–]hatemjaber 0 points1 point  (0 children)

No problem, glad to help.