How to get path for a swap on Quickswap/SushiSwap/etc

I could have sword the Moralis API had a method to find a path of addresses similar to what QuickSwap/SushiSwap do when doing a swap.

Building a trading bot, so hoping to avoid just using a simple TokenIn > Matic > TokenOut path, as I’m assuming that will have a negative impact on price, given that QuickSwap will often find a different path when swapping tokens.

Before I was using Moralis, I was getting prices from some price-feed contracts, and I could have sworn, that while trying to figure out this same problem, I saw someone answer it by saying they worked for Moralis, and that there was a function in the API that did that, and now for the life of me I can’t find that post, or anything in the API documentation about getting optimal paths for swaps.