in order to that I need a python library. which I'm sure there is one but I don't know where to find it.
You could check GitHub or PyPi[1] for list of Python library/software. You might want to check pycoin[2] and bitcoinlib[3] library which support Bitcoin and some altcoin.