Swagger Service response deserialization

I have a Swagger API endpoint which has a return type Task<IEnumerable> This returns correct data as I do a GET request through the Browser and it generates correct results.

I generated the service API call code as following using Radzen Pro tool.

var response = await httpClient.SendAsync(message);
 
            response.EnsureSuccessStatusCode();
 
            using (var stream = await response.Content.ReadAsStreamAsync())
            {
                return await JsonSerializer.DeserializeAsync<IEnumerable<SoftwareImageDto>>(stream, new JsonSerializerOptions
                {
                    PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
                    PropertyNameCaseInsensitive = true,
                });
            }

I am trying to invoke above method which has return type Task<IEnumerable> .

var resFromAPI = await Wmdsui.GetApiSoftwareItemFilterSoftwareImageDataFilters(serializedReq);

The results are different in resFromAPI than I expect. I am am not able to deserialize it to List.
I see different object being generated, although it has data inside it with properties _items.

I am afraid I can't see the screenshot - it is too small to reveal any meaningful information. Probably something in the Swagger definition is off though and Radzen could have generated wrong code for it. We can't be sure as we don't have access to the actual swagger definition and REST API that you are using. You can check the API JSON response and compare it with the swagger definition that you have.

The serialization was being done for properties of IEnumerable/List as well. The screenshot shows size, count, items all IEnumerable properties and operations. The data in _items is actual data I was looking for. Although without any further modification this is used by Radzen grid component and works as expected.