US president says he held off a scheduled attack on Iran after pressure from Gulf allies as renewed talks gain momentum.