regionId.
The SDK keeps that raw identifier and, when the value is known, adds a derived
regionLabel on public club information.
Beginner example
clubs.search applies the same enrichment to nested clubInfo when a
regionId is present. Match club details use the same ClubInfo shape, so
they receive regionLabel too.
Known regions
Labels are copied exactly from EA, including
Australia/NewZealand.
Mapping and helper
REGION_LABELSis a frozen object whose keys are the EA IDs as strings.KnownRegionIdandRegionLabelare derived from that constant.resolveRegionLabelacceptsstring | number | null | undefined.- Surrounding whitespace on string IDs is ignored. There is no partial match and no numeric coercion beyond the exact string or number EA sent.
- Consumers that only need the region table can import from the standalone
subpath
proclubs-sdk/regionswithout loading the HTTP client or native dependencies.
Drift detection
An unknownregionId is valid at runtime so a new EA region cannot break
clubs.get or clubs.search. The structural drift detector
from issue #17 can report that ID as unknown_value on a live compatibility
check. Maintainers then confirm the EA label and update REGION_LABELS
deliberately. The mapping does not depend on the full compatibility workflow.