In my local Bitcoin meetup, someone said Bitcoin is "programmable cash". Can someone please explain if and to what respect this is true? I read about a few BIP (Bitcoin improvement proposals) that specify something about that, but I'm not sure I'm getting the complete picture. Thanks in advance for your help!
Bitcoin transactions are essentially the movement of coins, by encumbering the coins with a restriction on who may redeem them. Bitcoin's internal scripting language is used to accomplish this.The restrictions can be overcome by the owner of the coins, since only they can meet the requirements of that script.
An example is a pay-to-pubkey script. The network interprets this as: whoever can produce a signature from the private key of this public key, can spend the coins. It looks like this: [public key] OP_CHECKSIG.
To redeem the coins, one provides a the right signature.
Scripts can have varying degrees of complexity. For example: OP_IF OP_2 [pubkey1] [pubkey2] OP_2 OP_CHECKMULTISIG OP_ELSE [publickey3] OP_CHECKSIG OP_ENDIF.
This script ensures that coins can only be redeemed if the owners of pubkey1 and pubkey2 provide a signature for a suggested transaction, OR, if the owner of publickey3 provides a signature. If either of these conditions are met, then the coins can be spent. That makes it programmable on a very low level.
Scripts are evaluated by the network whenever a transaction occurs, ensuring that the signatures or data which is provided actually meets the needs of the restrictions on the funds.
And although distinct to bitcoins scripting language, since bitcoin software is usually networked to maintain up-to-date knowledge on which transactions are currently spent and unspent, you could write applications to move money around without any human intervention.
In a sense, most payments API's are programmable cash, but the scripting language bitcoin uses is as low as you can get.
The answer of Mallory-Erik falls a bit short.
Bitcoin uses Script to create and redeem transaction scripts. Spend to Address is the most commonly used, but it is also possible to script other schemes. Some you might have heard about already are multisignature addresses, and contracts.
Bitcoin Script is somewhat limited, as it is not Turing-complete, other than for example Ethereum.
Also check out:
- Useful alternative Bitcoin transaction scripts - Features a comprehensive list of other scripts, although 3 years old.
- How do Scripts work?
You may also find interesting questions filed under script.