pygeek_stellar/stellar_requests.py
def establish_trustline(source_account_address, source_account_seed, destination_account_address,
                        token_code, token_limit, transaction_memo=''):
    """
    This method is used to create a trustline for a given token code and up to the specified limit,
    with the specified destination account address.
    :param str source_account_address: Address of the account from which the funds will be sent.
    :param str source_account_seed: Seed of the account from which the funds will be sent.
    :param str destination_account_address: Destination address.
    :param str token_code: Code of the token to be sent.
    :param str token_limit: Token limit value of the trustline.
    :param str transaction_memo: Text memo to be included in Stellar transaction. Maximum size of 28 bytes.
    """
    if not is_seed_matching_address(source_account_seed, source_account_address):
        print("The trustline could not be established. Either the given source account address or source"
              "account seed are invalid or they do not match.")
        return

    if not is_address_valid(destination_account_address):
        print('The given destination address is invalid')
        return
    if destination_account_address == source_account_address:
        print('Sending change of trust transaction to own address. This is not allowed')
        return
    if not is_transaction_text_memo_valid(transaction_memo):
        print('The maximum size of the text memo is {} bytes'.format(STELLAR_MEMO_TEXT_MAX_BYTES))
        return

    operations = [create_trust_op(destination_account_address,
                                  token_code,
                                  token_limit,
                                  source_account_address)]
    response = submit_operations(source_account_seed, operations, transaction_memo)
    #process_server_payment_response(response)

    This method is used to create a trustline for a given token code and up to the specified limit,
    with the specified destination account address.
    :param str source_account_address: Address of the account from which the funds will be sent.
    :param str source_account_seed: Seed of the account from which the funds will be sent.
    :param str destination_account_address: Destination address.
    :param str token_code: Code of the token to be sent.
    :param str token_limit: Token limit value of the trustline.
    :param str transaction_memo: Text memo to be included in Stellar transaction. Maximum size of 28 bytes.
    
This method is used to create a trustline for a given token code and up to the specified limit,
with the specified destination account address.
This method is used to create a trustline for a given token code and up to the specified limit with the specified destination account address .
def establish_trustline(source_account_address, source_account_seed, destination_account_address,
                        token_code, token_limit, transaction_memo=''):
    if not is_seed_matching_address(source_account_seed, source_account_address):
        print("The trustline could not be established. Either the given source account address or source"
              "account seed are invalid or they do not match.")
        return
    if not is_address_valid(destination_account_address):
        print('The given destination address is invalid')
        return
    if destination_account_address == source_account_address:
        print('Sending change of trust transaction to own address. This is not allowed')
        return
    if not is_transaction_text_memo_valid(transaction_memo):
        print('The maximum size of the text memo is {} bytes'.format(STELLAR_MEMO_TEXT_MAX_BYTES))
        return
    operations = [create_trust_op(destination_account_address,
                                  token_code,
                                  token_limit,
                                  source_account_address)]
    response = submit_operations(source_account_seed, operations, transaction_memo)
def establish_trustline ( source_account_address , source_account_seed , destination_account_address , token_code , token_limit , transaction_memo = '' ) : if not is_seed_matching_address ( source_account_seed , source_account_address ) : print ( "The trustline could not be established. Either the given source account address or source" "account seed are invalid or they do not match." ) return if not is_address_valid ( destination_account_address ) : print ( 'The given destination address is invalid' ) return if destination_account_address == source_account_address : print ( 'Sending change of trust transaction to own address. This is not allowed' ) return if not is_transaction_text_memo_valid ( transaction_memo ) : print ( 'The maximum size of the text memo is {} bytes' . format ( STELLAR_MEMO_TEXT_MAX_BYTES ) ) return operations = [ create_trust_op ( destination_account_address , token_code , token_limit , source_account_address ) ] response = submit_operations ( source_account_seed , operations , transaction_memo )
This method is used to create a trustline for a given token code and up to the specified limit,
with the specified destination account address.
This method is used to create a trustline for a given token code and up to the specified limit with the specified destination account address .
"""
    This method is used to create a trustline for a given token code and up to the specified limit,
    with the specified destination account address.
    :param str source_account_address: Address of the account from which the funds will be sent.
    :param str source_account_seed: Seed of the account from which the funds will be sent.
    :param str destination_account_address: Destination address.
    :param str token_code: Code of the token to be sent.
    :param str token_limit: Token limit value of the trustline.
    :param str transaction_memo: Text memo to be included in Stellar transaction. Maximum size of 28 bytes.
    """ #process_server_payment_response(response)
source_account_address
Address of the account from which the funds will be sent.
Address of the account from which the funds will be sent .
source_account_seed
Seed of the account from which the funds will be sent.
Seed of the account from which the funds will be sent .
destination_account_address
None
token_code
Code of the token to be sent.
Code of the token to be sent .
token_limit
Token limit value of the trustline.
Token limit value of the trustline .
transaction_memo
Text memo to be included in Stellar transaction. Maximum size of 28 bytes.
Text memo to be included in Stellar transaction . Maximum size of 28 bytes .