import { z as a } from "zod";
import { nearRpcClient as i } from "./rpc.js";
import { getBlockReference as m } from "./getBlockReference.js";
import { decodeQueryResult as s } from "./decodeQueryResult.js";
const l = async ({
  contractId: e,
  methodName: r,
  args: t,
  blockId: o,
  finality: n
}) => {
  const c = await i.query({
    request_type: "call_function",
    account_id: e,
    method_name: r,
    args_base64: btoa(JSON.stringify(t)),
    ...m({ blockId: o, finality: n })
  });
  return s(c, a.unknown());
};
export {
  l as queryContract
};
//# sourceMappingURL=queryContract.js.map
