Ripe red flesh is generally safe in small amounts. Green tomatoes, stems and leaves contain tomatine/solanine — toxic.
Ripe flesh only, tiny amounts. Green parts are toxic.
Ripe fruit mostly safe; green plant parts contain glycoalkaloids.