rssNewsArticles static method

Future<NewsArticleRssResponseResponse> rssNewsArticles(
  1. HttpClient client,
  2. String categoryfilter,
  3. bool includebody,
  4. String pageToken,
)

Returns a JSON string response that is the RSS feed for news articles.

Implementation

static Future<NewsArticleRssResponseResponse> rssNewsArticles (
    HttpClient client,
    String categoryfilter,
    bool includebody,
    String pageToken,
) async {
    final Map<String, dynamic> params = Map<String, dynamic>();
    final String _pageToken = '$pageToken';
    params['categoryfilter'] = categoryfilter;
    params['includebody'] = includebody;
    final HttpClientConfig config = HttpClientConfig('GET', '/Content/Rss/NewsArticles/$_pageToken/', params);
    config.bodyContentType = null;
    final HttpResponse response = await client.request(config);
    if(response.statusCode == 200) {
        return NewsArticleRssResponseResponse.asyncFromJson(response.mappedBody);
    }
    throw Exception(response.mappedBody);
}