SpecKit / Blueprint library

AI PRD Generator for coding agents.

Turn a product idea into requirements, an API contract, and tests your coding agent can follow. See how one booking rule connects them.

Sample brief01 / 01

Futsal court booking

“Let players reserve a court online. If two players pick the same slot, only one should get it.”

One slot. Two players.

Maya and Ari both see Court A available at 19:00. What should happen when they tap Reserve together?

PRD.md

What counts as a booking?

FR-01 · A signed-in player can reserve an available slot. At most one booking may exist for each court and slot, even when requests arrive together. Payments and cancellations are outside this example.

DATABASE.md

Make the rule hold in storage

Each slot belongs to one court and one start time. Bookings reference a slot and a player. Enforce a unique constraint on bookings.slot_id: a second insert must fail even if both players saw the slot as available.

API.md

Tell the second player what happened

POST /api/bookings · { "slot_id": "court-a-1900" }

Take the player identity from the session and the slot from the request. Return 201 Created after the booking is saved. If that slot is already booked, return 409 Conflict with SLOT_TAKEN; prompt the player to choose another slot.

TESTING.md

Prove it with concurrent requests

Given an empty slot, submit two authenticated booking requests together, one per player. Expect exactly one 201, one 409 with SLOT_TAKEN, and one stored booking for the slot. Either player can win.

Your turn

What are you building?

Describe your idea, answer a few questions, then review the first draft in your workspace.