Skip to content

Latest commit

 

History

History
85 lines (60 loc) · 2.64 KB

File metadata and controls

85 lines (60 loc) · 2.64 KB

Write-up

This is the skeleton - replace everything in blockquotes with your own words and delete the prompts as you go. Aim for ~300 words across the four questions; the route reference below can be as long as it needs to be.

Write it like you're handing the work to a teammate. We'd rather read an honest "I ran out of time on X and here's what I'd do" than a polished list of accomplishments. Submit this even if you didn't finish - see CHALLENGE.md.

1. What did you build for Part B, and why that?

What made you pick it over everything else you could have built? This is the question we care most about - the why matters more than the what.

2. What did you decide, and what did you rule out?

Route shapes, data model, where the logic lives, what you deliberately didn't do. Name a tradeoff you're not sure you got right.

3. Where did you cut corners?

What would you fix first with another day?


Part B: routes

Every endpoint you added, with its request and response shapes, so we can exercise it without reverse-engineering your code. Add or remove rows as needed; delete this section if your Part B added no routes.

Method and path What it does Success Errors
GET /api/... 200 + 404 if ...
POST /api/... 201 + 400 on ...

POST /api/...

// request
{ }

// 201 response
{ }

Schema changes

Any migrations you added (002_*.sql, ...), new tables or columns, and anything a reviewer needs to run beyond ./setup.sh. Write "none" if there were none.

How I verified this

How you checked your work - the happy paths and the failures. curl commands, a Postman collection, a scratch script, screenshots: whatever you actually used. Paste the commands.

This is much faster for us to review than working it out ourselves, and it's how you show you checked the edge cases.

Part A - the contract table in CHALLENGE.md, every row including the error cases:

# e.g.
curl -i http://localhost:3000/api/restaurants          # 200 + array
curl -i http://localhost:3000/api/restaurants/99999    # 404
curl -i http://localhost:3000/api/restaurants/abc      # 404
curl -i -X POST http://localhost:3000/api/restaurants \
  -H 'Content-Type: application/json' \
  -d '{"name":"Out Of Range","rating":6}'              # 400

Part B - the equivalent cases for what you built:

Known issues / what I'd do next

Anything broken, unfinished, or that you know is wrong. Being upfront here costs you nothing and tells us a lot.