CO2-switchable oligoamine patches based on amino acids and their use to build polyelectrolyte containers with intelligent gating.