Skip to content

Fix WARDOGS kill requests requiring a JSON body - #45

Open
speccycy wants to merge 3 commits into
warcon-app:mainfrom
speccycy:fix/wardogs-kill-empty-json-body
Open

speccycy wants to merge 3 commits into
warcon-app:mainfrom
speccycy:fix/wardogs-kill-empty-json-body

Conversation

@speccycy

@speccycy speccycy commented Oct 4, 2026

Copy link
Copy Markdown

Summary

WARDOGS now rejects POST /v1/players/{id}/kill when the request has no body.

Observed on a live server:

POST /v1/players/{id}/kill
(no body)
-> 501 unsupported_transfer_encoding
-> "The request could not be parsed."

Sending an empty JSON object succeeds:

POST /v1/players/{id}/kill
Content-Type: application/json

{}
-> 200 OK

This PR sends {} for both kill call sites:

  • the regular Kill action, which is also used by AFK protection and rule kills
  • the respawn kill after changeTeam

It also adds regression tests that assert the empty JSON body is sent.

Why

Without this, manual Kill fails and AFK protection rounds fail with:

The request could not be parsed.

on current WARDOGS builds.

Validation

Live RCON validation:

  • no body: 501 unsupported_transfer_encoding
  • {} body: 200 OK
  • player was killed successfully

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant