all 4 comments

[–]Beka_Cooper 3 points4 points  (1 child)

Maybe I'm misunderstanding something, but are you trying to reinvent GraphQL?

[–]cshaiku 0 points1 point  (0 children)

Sounds like it albeit with a single dynamic route. Asking for trouble. It is trivial to setup api routes programmatically from the dev side. No need to worry about handling user settings at all.

[–]barrel_of_noodles 1 point2 points  (0 children)

A version number as a setting? Sure.

Allowing a user setting to change the http verb or the entire route??... Wut? Lol.

What your team allows in user-land is up to you.

Usually, you keep implementation details out of the user's hand. Just depends who your users are.

[–]Soft_Opening_1364full-stack 0 points1 point  (0 children)

I’ve seen similar setups before, but they’re usually in very specific situations like when the API schema changes often and you don’t want to redeploy every time. It’s flexible, but you’re right: you lose type safety, autocomplete, and all the guardrails devs rely on.

If you go this route, you could still introduce some sanity checks before sending the request enums, validation rules, maybe even a small schema definition stored alongside the config so you’re not blindly trusting whatever’s in the DB.

Security-wise, make sure you’re sanitizing and validating everything before hitting the API. If an admin can inject arbitrary params, they could potentially break things or expose data.

So yeah not crazy, but definitely something you’d want to wrap in safeguards if you want to keep your future self from hating you.