Balance a foursome
Compare one proposed 2v2 pairing for four players you already know. This does not create a booking or a match.
Prerequisites
- Four distinct public player UUIDs (from your earlier player lookups)
- API key with
read:intelligence(test keys work)
Recommended sequence
- Resolve each participant to a PadelRank player id
- Propose court order: A-left, A-right, B-left, B-right
- Call
POST /v1/intelligence/predict - Show
balance_ratingand optionallydraw_probabilityin your session UI
Code
curl -s -X POST "https://api.padelrank.me/v1/intelligence/predict" \
-H "Authorization: Bearer $PADELRANK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"player_ids": [
"11111111-1111-4111-8111-111111111111",
"22222222-2222-4222-8222-222222222222",
"33333333-3333-4333-8333-333333333333",
"44444444-4444-4444-8444-444444444444"
],
"format": "2v2"
}'{
"draw_probability": 0.11,
"balance_rating": "medium",
"team_a": ["…", "…"],
"team_b": ["…", "…"]
}How to interpret the result
- Compare
draw_probabilityacross alternative pairings of the same four players high/medium/lowmap to thresholds 0.12 and 0.07- A higher value is the more even of the pairings you compared — not a tie guarantee
Errors
422if ids are not four distinct public players- Unknown or private players surface as validation /
unknown_or_private_player
Reference: Predict