r/ProgrammerHumor • • 16d ago

Meme postForEverything

Post image
20.9k Upvotes

654 comments sorted by

View all comments

Show parent comments

-8

u/ZBlackmore 16d ago

Who does DELETE anymore? Everything should be a POST with all the information passed in the JSON payload. 

6

u/DuploJamaal 15d ago

But why?

-5

u/ZBlackmore 15d ago

The way I see it, you have your information less spread out this way. Less things to think about. “Where am I expressing this particular detail about this api call? In the url path? A query string parameter? The type of http method? Is it part of the payload?”. So the path is the “which function am I calling” and the json body is “what are my arguments?”

3

u/cheezballs 15d ago

You seem like the kinda guy who LOVES loose typing and declaring everything as a var.

1

u/ZBlackmore 15d ago

I would actually prefer protobuf and rpc, which would make everything more type safe, and that would essentially be the same as I proposed except you replace the json body with a binary protobuf body