Movatterモバイル変換


[0]ホーム

URL:


Skip to content
DEV Community
Log in Create account

DEV Community

Cover image for RESTful verbs vs Real actions
Tobias Nickel
Tobias Nickel

Posted on

     

RESTful verbs vs Real actions

In http rest APIs we are stuck with a very limited set of verbs. They are essentially:

  • get: to load data
  • post: to create new data
  • put: to replace data
  • patch: to update data
  • delete: to remove data

These are the verbs of a typical CRUD operation. They are very effective. But let me tell you a story:

In the afternoon you patch your location to your mothers house. After that you get her data and patch her status to happy.

This is a small situation, told as if you tell a story to a database. Here is the same story, but for the application layer:

In the afternoon you drive into the city to your mothers house. After you see her, you notice her pretty dress. You make her a nice compliment. That makes her very happy.

What version of the story do you prefer?

Top comments(0)

Subscribe
pic
Create template

Templates let you quickly answer FAQs or store snippets for re-use.

Dismiss

Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment'spermalink.

For further actions, you may consider blocking this person and/orreporting abuse

German Software Engineer sharinh thoughts
  • Location
    MUNICH Germany
  • Work
    Technical Lead
  • Joined

Trending onDEV CommunityHot

DEV Community

We're a place where coders share, stay up-to-date and grow their careers.

Log in Create account

[8]ページ先頭

©2009-2025 Movatter.jp