I am new in ethereum blockchain and I am trying to understand completely how it works.
I have read this document, but there are still some points which are not obvious to me. One of these points is about transactions. In other words, I can't understand the exact structure and content of a transaction in ethereum.
As far as I am concerned, we have two types of accounts in ethereum. Regular accounts (Externally Owned Accounts - EOA) and contract accounts. Each account is identified by its address.
So, when we want to transfer some amount of money from EOA1 to EOA2 the transaction structure is:
- Sender Id: Address of EOA1
- Reciever Id: Address of EOA2
- Amount of money: for example 1 Ether
But how about a contract transaction? For example, Suppose we have a contract with address A which has a function named Func1. So, when we call Func1 a transaction is created. But what is the content of this transaction?
these are the fields:
- Invoker id
- Contract address: In this case A
- Gas price
- Total cost = gasUsed * gasPrice
Is this correct?