<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_tx_amount(cls, txid, txindex):
 """Gets the amount of a given transaction output. :param txid: The transaction id in question. :type txid: ``str`` :param txindex: The transaction index in question. :type txindex: ``int`` :raises ConnectionError: If all API services fail. :rtype: ``Decimal`` """


        for api_call in cls.GET_TX_AMOUNT_MAIN:
            try:
                return api_call(txid, txindex)
            except cls.IGNORED_ERRORS:
                pass

        raise ConnectionError('All APIs are unreachable.')