Entity Framework Core’s Remove method marks an entity for deletion when changes are saved. Consider whether permanent deletion is appropriate before using it. section 12.6
Remove is a data-persistence operation; HTTP DELETE is a request verb for an API endpoint. An API can use that verb to request deletion, but the verb and the EF Core method are not the same thing. section 5.2.2 section 12.6
Before deleting an entity, consider whether a soft delete is a better fit:
- A soft delete can use an IsDeleted flag and may be safer and easier to implement. section 12.6
Table 5.1 The minimal API map endpoints and the corresponding HTML verbs (view table figure)
| Fetch data only; no modification of state. May be safe to cache. |
||
Compare HTTP verbs to see where DELETE fits in an API; this describes endpoint behavior, not EF Core’s entity-removal method. section 5.2.2







