Fix policy error api