Help me consume IBM Watson NLU API

Yesterday I watched a video of a guy who consumed Watson'S (IBM cloud) Natural Language Understanding API with JS using Node and he did pretty cool things with it... On the other hand I'm trying to consume and see the results to do something, but I do not even know if I'm going the right way because it is the first thing I do something like and to make it worse there is no documentation for C #

To using the nugget pack IBM.WatsonDeveloperCloud.NaturalLanguageUnderstanding.v1

TokenOptions token = new TokenOptions
            {
                IamApiKey = "Minha ApiKey",
                ServiceUrl = "https://gateway.watsonplatform.net/natural-language-understanding/api"
            };

            var nlu = new NaturalLanguageUnderstandingService(token, "2018-12-19");

            var parametros = new Parameters { Text = "I'm Michael Jackson the king of POP"};

            var resultado = nlu.Analyze(parametros);

So far what I'm doing is putting a Breaking Point in "result" and seeing in what da and what da is not good! Results in the following error:

IBM.WatsonDeveloperCloud.NaturalLanguageUnderstanding.v1.dll: 'One or more errors occurred. (The API query failed with status code BadRequest | Bad Request / x-global-transaction-id: ffea405d5d1cfc0efeae7731 / X-DP-Watson-Tran-ID: gateway02-4272846641 | error: { "error": "no features specified", 'code': 400 })'

Author: Márcio Sebastião, 2019-07-03

1 answers

Out of my ignorance, I thought the answer was a mistake when in fact I was just implementing it the wrong way.

The API asks that at least one Feature be specified.... Before posting the doubt in the forum I had already tried to pass a feature, but had done it in the wrong way and so the "error", so I searched more and passed the feature in the correct way, it worked and it was like this:

TokenOptions token = new TokenOptions
        {
            IamApiKey = "Minha ApiKey",
            ServiceUrl = "https://gateway.watsonplatform.net/natural-language-understanding/api",
        };

        var nlu = new NaturalLanguageUnderstandingService(token, "2018-12-19");

        Features features = new Features();
        features.Keywords = new KeywordsOptions();

        var parametros = new Parameters { Text = "I'm Michael Jackson", Features = features };

        var resultado = nlu.Analyze(parametros).ResponseJson;

        Console.WriteLine(resultado);
 1
Author: Márcio Sebastião, 2019-07-04 01:08:59