My understanding of a bitcoin transaction is as follows. Each UTXO (that's not a null value UTXO like an OP_RETURN), has a value, scriptPubKey (hereafter referred to as a "locking script"), and index (hereafter referred to as "n").
In order to spend a UTXO, you have have to supply an unlocking script which contains a signature from the address possessing the UTXO (this proves that the spender actually has the private key for the address), and the UTXO owner's public key so the signature can be verified.
I made this diagram to show what I believe a bitcoin transaction spend to look like:
https://imgur.com/a/titAoheClearly I don't grasp the entire structure of a BTC transaction as indicated by the fact that I put several "IDK"s in the diagram. Can someone fill in the gaps in my knowledge?