Get fee for Nft Mint

recently, I have a lot of stuck transactions when minting, so I would like to estimate fees correctly.
I stumbled over rpc get_fee_estimate:

What is unclear to me: I cn specify a Spend bundle. When I mint an nft, I get a spend bundle. But at that time, The transaction is already sent to the mempool and too late to estimate fees.

Fees are probably not the reason for stuck transactions. The mempool is currently not full, so zero-fee transactions should make it into the next block.

If you are minting multiple NFTs, it’s best to use the bulk mint tool to prevent mempool issues.

zou are right, fees are not the issue.

nontheless, is there a way to estimate the required fee for a mint?

what I am currently thinking about is:
Do an nft mint with nft_mint_nft rpc. This yields a SpendBundle.

With the spendbundle I can execute get_fee_estimate as future mints hopefully have a simmilar clvm cost.

That RPC should (if it’s working) give an accurate estimate of the required fees at the moment when it is run. However, because the mempool currently isn’t busy, you can get in (at the back of the line) with zero fee, and you can get to the front of the line with a 1-mojo fee. If the mempool is full, then to mint an NFT with a DID, you’ll need to include a fee of 615 million mojos.

i understand that the transaction fee is 0 at the moment and that this rpc should do the work.

My question is for the future, how I can execute the get_fee_estimate rpc without sending a guessing transaction at first.
Because I only obtain the SpendBundle of a Mint after the minting, not before.
other way of doing it would be to calculate the clvm cost of the mint, but i havent found a reference on how to do that