private static async Task <bool> CreateSkillSet() { Console.WriteLine("Creating Skill Set..."); try { Skillset skillset = SearchResources.GetSkillset(SkillsetName, await KeyHelper.GetAzureFunctionHostKey(_httpClient), BlobContainerNameForImageStore); await _searchClient.Skillsets.CreateAsync(skillset); } catch (Exception ex) { if (DebugMode) { Console.WriteLine("Error creating skillset: {0}", ex.Message); } return(false); } return(true); }
private static async Task <bool> CreateSkillSet() { Console.WriteLine("Creating Skill Set..."); try { SearchIndexerSkillset skillset = SearchResources.GetSkillset(SkillsetName, BlobContainerNameForImageStore); await _searchIndexerClient.CreateSkillsetAsync(skillset); } catch (Exception ex) { if (DebugMode) { Console.WriteLine("Error creating skillset: {0}", ex.Message); } return(false); } return(true); }