handle api2 escaping