NAME

Blockchain::Ethereum::Transaction::EIP1559 - Ethereum Fee Market transaction abstraction

SYNOPSIS

Transaction abstraction for Legacy transactions

my $transaction = Blockchain::Ethereum::Transaction::EIP1559->new(
    nonce                    => '0x0',
    max_fee_per_gas          => '0x9',
    max_priority_fee_per_gas => '0x0',
    gas_limit                => '0x1DE2B9',
    to                       => '0x3535353535353535353535353535353535353535'
    value                    => '0xDE0B6B3A7640000',
    data                     => '0x',
    chain_id                 => '0x539'
);

$transaction->sign('4646464646464646464646464646464646464646464646464646464646464646');
my $raw_transaction = $transaction->serialize(1);
```

METHODS

sign

Check the parent transaction class for details Blockchain::Ethereum::Transaction

tx_format

Determines if all required fields for the transaction type are given.

Expected fields:

- chain_id
- nonce
- max_fee_per_gas
- max_priority_fee_per_gas
- gas_limit
- to
- value
- data
- access_list
- v
- r
- s

Returns a array reference containing the avaialble fields for the transaction type

serialize

Encodes the given transaction parameters to RLP

  • $signed boolean to idenfity if the transaction is already signed (adds v r s if true) or not

Returns the RLP encoded transaction bytes

set_v

Sets the v transaction field using the given y-parity

  • $y y-parity

Returns the v hexadecimal value also sets the v fields from transaction

AUTHOR

Reginaldo Costa, <refeco at cpan.org>

BUGS

Please report any bugs or feature requests to https://github.com/refeco/perl-ethereum-transaction

SUPPORT

You can find documentation for this module with the perldoc command.

perldoc Blockchain::Ethereum::Transaction::EIP1559

LICENSE AND COPYRIGHT

This software is Copyright (c) 2022 by REFECO.

This is free software, licensed under:

The MIT License