history api fix