Advanced
Batch Operations
Efficiently process multiple operations with batch APIs
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Efficiently process multiple operations with batch APIs
// Batch get scores
async function getLeaderboard(addresses) {
const scores = await Promise.all(
addresses.map(addr => zkScore.getScore(addr))
);
return addresses.map((addr, i) => ({
address: addr,
score: scores[i].total
})).sort((a, b) => b.score - a.score);
}