Handle amazon API errors