CAPB is a fatty acid amide containing a long hydrocarbon chain at one end and a polar group at the other. This allows CAPB to act as a surfactant and as a detergent. It is a zwitterion, consisting of both a quaternary ammonium cation and a carboxylate.