@renegade-fi/core
Version:
VanillaJS library for Renegade
15 lines • 609 B
JavaScript
import { ADMIN_GET_ORDER_MATCHING_POOL_ROUTE } from '../constants.js';
import { getRelayerWithAdmin } from '../utils/http.js';
export async function getOrderMatchingPool(config, parameters) {
const { orderId } = parameters;
const { getBaseUrl } = config;
try {
const res = await getRelayerWithAdmin(config, getBaseUrl(ADMIN_GET_ORDER_MATCHING_POOL_ROUTE(orderId)));
return res.matching_pool;
}
catch (error) {
console.error(`Failed to get matching pool for order ${orderId}`, { error });
throw error;
}
}
//# sourceMappingURL=getOrderMatchingPool.js.map