Twilio has updated its Authy API to meet the new European banking law, PSD2, which mandates stronger two-factor authentication for online payments. The updated API includes a new method called Transactional TOTP, which enhances time-based one-time passcodes to meet PSD2 requirements by tying the code to specific transaction attributes. This allows for more secure and compliant authentication, while also providing offline capabilities and protection against man-in-the-middle attacks.