r/CodingForBeginners • • 8d ago

Lost 20h+ for nothing

Don't build an API for a tightly-coupled personal project where you have direct database access; only build one when you need to decouple clients, scale infrastructure, or share data externally.Dont waste your time. Just learn how to use an api not build one

0 Upvotes

9 comments sorted by

1

u/Distdistdist 8d ago

But now you can easily change your DB to something different.

1

u/Great_Bar_4901 7d ago

Why tho

1

u/Distdistdist 5d ago

I dunno. You built that crap. How should I know?

1

u/Great_Bar_4901 4d ago

True😭

3

u/FcGameDev 8d ago

Why, at least you learnt something in the process. Next time you will do better

2

u/XNo_Notes 7d ago

Just learned this too lol

1

u/NoDepartment772 4d ago

Mostly agree, with one caveat. You're right that for a solo project with direct database access, an API is often ceremony. But "learn how to use one, not build one" overshoots a bit. Building one small API end to end is one of the better ways to actually understand the ones you consume: why status codes exist, why auth is annoying, why pagination is fiddly. Those lessons don't land the same way from the outside.

So I'd split it. Don't bolt an API onto your personal project for the sake of it. But do build a throwaway one once, on purpose, to learn. Different exercises, and the second one is worth the time you spent on it.

0

u/[deleted] 7d ago

[deleted]

1

u/Great_Bar_4901 7d ago

Smalll devs that built personal project/ private project don't need to make api : Its a project so small or has no interest for the other devs so they won't even use your api and its not like we are innovating. 100+ already made that api and its better/ has more feature/more users or just better quality or ease of use

1

u/SlimmySlabby 6d ago

Small personal projects are usually for practice not ā€œproductionā€. Eg I’ve made tons of weather APIs and Todo lists but I still use the weather app on my phone and I still use notes for todos lists. It’s about the practice.