Attempts API and its tests