import { getTokenPrices as e } from "../../API/getTokenPrice.mjs";
import { KYC_LIMIT as t } from "../../constants/kyc.constants.mjs";
import { transactionErrorCodes as n } from "../../error-handling/error-codes.constants.mjs";
import { getAmountInToken as r } from "../web3/etherFunctions.mjs";
import { getERC20Token as i } from "../utils/erc20tokenFunctions.mjs";
import "../../constants/index.mjs";
import "../../API/index.mjs";
import "../../error-handling/index.mjs";
import "../utils/index.mjs";
import "../web3/index.mjs";
//#region libs/shared/common/src/functions/kyc/checkTokenLimitsUSD.ts
var a = async (a, o, s) => {
	if (!o.length || !s.length) return !1;
	let c = o.map((e) => i(e, a)), l = [];
	try {
		l = (await e(a, o)).prices || [];
	} catch {
		throw Error(n.KYC_PRICE_FETCH_FAILED);
	}
	for (let e = 0; e < o.length; e++) {
		let n = c[e], i = s[e], a = l[e];
		if (!n || i === 0n || !a) continue;
		let o = r(n, i);
		if (Number(o) * a > t) return !0;
	}
	return !1;
};
//#endregion
export { a as checkTokenLimitsUSD };
