Go to file
2026-05-17 21:53:04 +07:00
app feat: add invalidation 2026-05-17 21:53:04 +07:00
bootstrap feat: add routes and bootstrap 2026-05-17 21:16:32 +07:00
config feat: add config 2026-05-17 19:25:50 +07:00
database feat: add seeder 2026-05-17 21:22:53 +07:00
public feat: init laravel 2026-05-17 18:59:08 +07:00
resources feat: init laravel 2026-05-17 18:59:08 +07:00
routes fix: bugs 2026-05-17 21:48:34 +07:00
storage feat: init laravel 2026-05-17 18:59:08 +07:00
tests feat: init laravel 2026-05-17 18:59:08 +07:00
.editorconfig feat: init laravel 2026-05-17 18:59:08 +07:00
.env.example feat: fix env and start 2026-05-17 21:29:05 +07:00
.gitattributes feat: init laravel 2026-05-17 18:59:08 +07:00
.gitignore feat: init laravel 2026-05-17 18:59:08 +07:00
artisan feat: init laravel 2026-05-17 18:59:08 +07:00
composer.json feat: init laravel 2026-05-17 18:59:08 +07:00
composer.lock feat: init laravel 2026-05-17 18:59:08 +07:00
docker-compose.yml feat: fix env and start 2026-05-17 21:29:05 +07:00
Dockerfile feat: init docker 2026-05-17 18:56:40 +07:00
package.json feat: init laravel 2026-05-17 18:59:08 +07:00
phpunit.xml feat: init laravel 2026-05-17 18:59:08 +07:00
README.md feat: add readme 2026-05-17 21:48:44 +07:00
vite.config.js feat: init laravel 2026-05-17 18:59:08 +07:00

Start

git clone ...
docker compose up -d

Доступность

curl -s "http://localhost:8080/api/slots/availability"

Создать hold

curl -s -X POST "http://localhost:8080/api/slots/1/hold" \
    -H "X-Idempotency-Key: 3f36b498-4144-43d3-9853-b22379b520ff"

Подтвердить

curl -s -X POST "http://localhost:8080/api/holds/1/confirm"

Отменить

curl -s -X DELETE "http://localhost:8080/api/holds/1"

Oversell

curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: 20ff64a3-43d6-4ddb-874e-441d0a87570e"
    
curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: d7db5b73-1ea5-4156-99b6-dbace1b483a9"
    
curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: ddd6174c-0fda-4765-8413-12dd3cda9692"
    
curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: 7af943b4-dfcf-4d5e-99c0-fa06fc9b2a6a"
    
curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: fcb4b745-e928-4af3-bb35-c307cc5a574e"
    
curl -s -X POST "http://localhost:8080/api/slots/2/hold" \
    -H "X-Idempotency-Key: 38ae0adb-7f23-40c0-9ac1-069a15d89a98"