• Probe all regions for a given network and return them sorted by latency. The first element is the fastest healthy region.

    Parameters

    Returns Promise<LatencyProbeResult[]>

    const results = await autoSelectRegion(SynapseNetwork.Mainnet);
    const best = results[0]; // fastest healthy region
    const client = SynapseClient.fromEndpoint({ ...best.endpoint, apiKey: '...' });