EddieHubCommunity / api

API to manage our community data

Home Page:https://api.eddiehub.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

> Spike Put-Endpoints for Entities

Cahllagerfeld opened this issue · comments

When doing patch, the whole object should be replaced.

I believe the PUT method does this, not PATCH. I'm not familiar with the implementation but if the payload sent on the HTTP request only contains a few fields to update, then it should use the PATCH method.
From what I saw on the calendar feature test, the PUT request doesn't send the fields createdOn and updatedOn so this should be indeed changed to PATCH.

In my opinion, Web APIs should strive to use PUT instead of PATCH whenever possible, simply because PUT is idempotent. Although PATCH can be idempotent depending on the implementation.

Originally posted by @BOLT04 in #207 (comment)

Thank you for raising 👍

I think we some things, like bot commands, for example setting the bio, it will only have a limited amount of data, so this should use patch

Stale issue message

this is still needed or not @Cahllagerfeld ?