A follow up question...I understand that if an address has a transaction, then the public key can then be known. That’s why bitcoin generally uses new addresses every time. How can I find the public key in the event that the address has a transaction? The address I’m looking for does not, but I’m just asking to learn in this case.
You would have to find the transaction, parse it as a standard Bitcoin transaction, and look at the inputs to see if any of the public keys hash to the hash encoded by your address. Bitcoin Core does not store transactions by association to the address, and addresses nor their data are contained in the inputs of a transaction.
Note that transactions can also be associated by the outputs. In that case, the public key is not known, however the hash provided in the output will be the same hash encoded by the address.