accesscodes/test-platform-names.sh
anonymousratwastaken 661df0616b tried to fix things
2025-12-20 07:56:12 +00:00

23 lines
812 B
Bash

#!/bin/bash
# Test script to verify platform names are sent correctly to server
echo "Testing platform name mapping..."
# Test Java player - should send "java username" as platform
echo -e "\n=== Java Player Platform Test ==="
curl -X POST http://localhost:3000/api/resolve-player \
-H "Content-Type: application/json" \
-d '{"type": "java", "username": "Notch"}' \
| jq .
# Test Bedrock player - should send "bedrock gamertag" as platform
echo -e "\n=== Bedrock Player Platform Test ==="
curl -X POST http://localhost:3000/api/resolve-player \
-H "Content-Type: application/json" \
-d '{"type": "bedrock", "username": "TestGamertag"}' \
| jq .
echo -e "\n=== Platform Mapping Complete ==="
echo "Java platform should be: 'java username'"
echo "Bedrock platform should be: 'bedrock gamertag'"