CognitiveServices Language TextAnalytics API is not working

Narayanasetti, Vinodh Kumar 0 Reputation points
2025-10-15T11:30:20.7+00:00

I have used this package Microsoft.Azure.CognitiveServices.Language.TextAnalytics version 3.0.0 in one of my legacy application.

var client = new TextAnalyticsClient(new ApiKeyServiceClientCredentials(cognitiveConfiguration))
 {
     Endpoint = cognitiveConfiguration.Endpoint
 };

 var kpResults = await client.KeyPhrasesAsync(
                true,
                new MultiLanguageBatchInput(
                    new List<MultiLanguageInput>
                    {
         new MultiLanguageInput(language, "1", query)
                    }));
  • client.KeyPhrasesAsync method is throwing below exception suddenly.

Error response:

"StatusCode": 3,

"ActivityId": "4000000a-0001-fd00-b63f-84710c7967bb",

"Errors": 

        "Code": -2146233088,

        "Message": "Operation returned an invalid status code 'Gone'",

        "FullMessage": "Exception: Microsoft.Azure.CognitiveServices.Language.TextAnalytics.Models.ErrorResponseException\r\n

After troubleshooting i've found that client.KeyPhrasesAsync uses this request url https://{{region}}.api.cognitive.microsoft.com//text/analytics/v2.1/keyPhrases?showStats=true and most of the articles were saying v2.1 has been retired on February 2024 but am not getting, how this was working till Oct 7th 2025.

Is anyone facing similar issue ? Can someone please provide suggestion on fixing this issue.

Azure Language in Foundry Tools
Azure Language in Foundry Tools

An Azure service that provides natural language capabilities including sentiment analysis, entity extraction, and automated question answering.

0 comments No comments

1 answer

Sort by: Most helpful
  1. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.

    2 deleted comments

    Comments have been turned off. Learn more

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.