Skip to content

RESTful endpoint naming #151

Description

@tbtommyb

Endpoints like app.get("/api/history/:station") and app.get("/api/history/:station/case/:id") are well-named but ones like app.post("/api/add-case/:station") are a little confusing.

Generally it is good to try and only refer to the resource name in the end point and then specify the behaviour you want with the HTTP verb. So adding a case to a station would be via a POST to something like /api/stations/:stationId/case.

Metadata

Metadata

Assignees

Labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions