Update smoke test and docs for suggestion delete endpoint
This commit is contained in:
@@ -61,6 +61,7 @@ Do not introduce MVC controllers, Razor Pages, Blazor, or SPA frameworks.
|
|||||||
7. Results phase (aggregated leaderboard)
|
7. Results phase (aggregated leaderboard)
|
||||||
8. Admin controls (phase switch, reset)
|
8. Admin controls (phase switch, reset)
|
||||||
9. Factory reset (clear all data including players) for fresh testing/deploy
|
9. Factory reset (clear all data including players) for fresh testing/deploy
|
||||||
|
10. Suggest delete (players can delete their own suggestions during Suggest phase)
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
1
API.md
1
API.md
@@ -12,6 +12,7 @@ POST /api/me/name
|
|||||||
## Suggestions
|
## Suggestions
|
||||||
GET /api/suggestions/mine
|
GET /api/suggestions/mine
|
||||||
POST /api/suggestions
|
POST /api/suggestions
|
||||||
|
DELETE /api/suggestions/{id}
|
||||||
GET /api/suggestions/all
|
GET /api/suggestions/all
|
||||||
|
|
||||||
## Votes
|
## Votes
|
||||||
|
|||||||
@@ -61,6 +61,10 @@ $ids = @()
|
|||||||
$resp | Out-Host
|
$resp | Out-Host
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Write-Host "`n4b) Delete the third suggestion (Suggest phase only)"
|
||||||
|
Invoke-Json -Method DELETE -Path "/api/suggestions/$($ids[2])" | Out-Host
|
||||||
|
$ids = $ids[0..1]
|
||||||
|
|
||||||
Write-Host "`n5) Reveal phase"
|
Write-Host "`n5) Reveal phase"
|
||||||
Invoke-Json -Method POST -Path "/api/admin/phase" -Headers @{ "X-Admin-Key" = $AdminKey } -Body @{ phase = "Reveal" } | Out-Host
|
Invoke-Json -Method POST -Path "/api/admin/phase" -Headers @{ "X-Admin-Key" = $AdminKey } -Body @{ phase = "Reveal" } | Out-Host
|
||||||
Invoke-Json -Method GET -Path "/api/suggestions/all" | Out-Host
|
Invoke-Json -Method GET -Path "/api/suggestions/all" | Out-Host
|
||||||
|
|||||||
Reference in New Issue
Block a user