1.7 define /todo/{id} DELETE endpoint

Will Barnes
Jul 10, 2017 · 1 min read

wb todoMVC Master >> 1.7 define /todo/{id} DELE…

Update 7/19

OpenAPI3 (aka swagger3) is just about ready for official release. This means steps 1.1–1.x will need to be rewritten soon. The folks over at swagger-api are working hard updating the many swag tools to work with the latest spec.


If you have not implemented CORS this step will fail. See how to implement CORS here.

Regarding returning 204 responses: some legacy browsers (IE11, various SmartTVs) choke on 204. Swagger editor in mock mode also chokes on 204 As a result we will use a 200 with some string response to represent a successful delete


Run swagger editor & server in mock mode if not running already.

Define DELETE action under Paths: /todo/{id} in swagger.yaml


Tutorial Navigation

The master tutorial doc is located here: WB todoMVC MASTER

Previous Step: 1.6 define /todo/{id} path and define GET endpoint.

Next Step: 1.8 define /todo/{id} PUT endpoint

Will Barnes

Written by

An intelligent fool, stubbornly optimistic, relentlessly persistent, tech-cofounder at cProject

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade