VOOZH about

URL: https://www.nuget.org/packages/CodeHelper.API.NYTimes/

⇱ NuGet Gallery | CodeHelper.API.NYTimes 1.2.2




👁 Image
CodeHelper.API.NYTimes 1.2.2

dotnet add package CodeHelper.API.NYTimes --version 1.2.2
 
 
NuGet\Install-Package CodeHelper.API.NYTimes -Version 1.2.2
 
 
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="CodeHelper.API.NYTimes" Version="1.2.2" />
 
 
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="CodeHelper.API.NYTimes" Version="1.2.2" />
 
Directory.Packages.props
<PackageReference Include="CodeHelper.API.NYTimes" />
 
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add CodeHelper.API.NYTimes --version 1.2.2
 
 
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: CodeHelper.API.NYTimes, 1.2.2"
 
 
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package CodeHelper.API.NYTimes@1.2.2
 
 
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=CodeHelper.API.NYTimes&version=1.2.2
 
Install as a Cake Addin
#tool nuget:?package=CodeHelper.API.NYTimes&version=1.2.2
 
Install as a Cake Tool
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

CodeHelper.API.NYTimes

CodeHelper.API.NYTimes is a lightweight and simple .NET Wrapper to get links and metadata for Times' articles as soon as they are published on NYTimes.com. The Times Newswire API provides an up-to-the-minute stream of published articles. You can filter results by source (all, nyt, inyt) and section (arts, business, ...).

Info + Question?

Support

You can support the work if you want:

Dependencies

Version

  • 1.2.2 : Get Movie critic names, Get Crtics Picks, Search Movie Reviews
  • 1.1.0 : Get Best Seller Lists, Get Books on a specific list, Get NYT Book reviews by author¦isbn¦title
  • 1.0.0 : Get Sections, Get Latest Articles, Get Top Stories, Get Most Popular, Article Search, Article Archives

Methods

  • NYTimesArticlesHelper.GetSections() : Returns the available sections, like Arts, Business,...

  • NYTimesArticlesHelper.GetLatestArticles(string source = SourceTypes.All, string section = "all") : Get links and metadata for NY Times' articles as soon as they are published on NYTimes.com.

  • NYTimesArticlesHelper.GetTopStories(string section = "home") : Returns an array of articles currently on the specified section (arts, business, ...).

  • NYTimesArticlesHelper.GetMostPopularArticles(string resourceType = "", int period=1, string sharedType = "") : Returns the most popular articles on NYTimes.com based on emails, shares, or views for specified period of time (1 day, 7 days, or 30 days).

  • NYTimesArticlesHelper.ArticleSearch(string qurey, int page = 0) : Look up articles by keyword.

  • NYTimesArticlesHelper.GetArticleArchive(int year, int month) : Returns an array of NYT articles for a given month, going back to 1851.

  • NYTimesBooksHelper.GetBestSellerLists() : Returns a list of all the NYT Best Sellers Lists.

  • NYTimesBooksHelper.GetBookReviews(string reviewByType, string reviewByValue) : Returns a list NYT book review by author, ISBN, or title.

  • NYTimesMoviesHelper.GetCriticNames() : Returns a list of movie critic names

  • NYTimesMoviesHelper.GetCriticsPicks() : Returns a list of movie reviews that are critics' picks

  • NYTimesMoviesHelper.Search(string query, string dateFrom, string dateTo) : Returns a list of movie reviews bases on words in the titke (query)

Use of Code

using CodeHelper.API.NYTimes;
using CodeHelper.API.NYTimes.Articles;

NYTimesArticlesHelper _helper = new() { ApiKey = "YOUR_NYTIMES_API_TOKEN"" };
var _articles = _helper.GetTopStories("arts");

NYTimesBooksHelper _helperBooks = new() { ApiKey = "YOUR_NYTIMES_API_TOKEN"" };
var _lists = await _helperBooks.GetBestSellerLists();
var _books = await _helperBooks.GetBooksOnList("hardcover-fiction");
var _reviews = await _helperBooks.GetBookReviews(ReviewByTypes.Author, "Stephen King");

NYTimesMoviesHelper _helperMovies = new() { ApiKey = "YOUR_NYTIMES_API_TOKEN"" };
var _critics = _helperMovies.GetCriticNames();

Authentication

NY Times API uses API key to authenticate requests. You can view and manage your API keys in the My Apps page https://developer.nytimes.com/my-apps

Usage

Product Versions Compatible and additional computed target framework versions.
.NET net6.0 net6.0 is compatible.  net6.0-android net6.0-android was computed.  net6.0-ios net6.0-ios was computed.  net6.0-maccatalyst net6.0-maccatalyst was computed.  net6.0-macos net6.0-macos was computed.  net6.0-tvos net6.0-tvos was computed.  net6.0-windows net6.0-windows was computed.  net7.0 net7.0 was computed.  net7.0-android net7.0-android was computed.  net7.0-ios net7.0-ios was computed.  net7.0-maccatalyst net7.0-maccatalyst was computed.  net7.0-macos net7.0-macos was computed.  net7.0-tvos net7.0-tvos was computed.  net7.0-windows net7.0-windows was computed.  net8.0 net8.0 was computed.  net8.0-android net8.0-android was computed.  net8.0-browser net8.0-browser was computed.  net8.0-ios net8.0-ios was computed.  net8.0-maccatalyst net8.0-maccatalyst was computed.  net8.0-macos net8.0-macos was computed.  net8.0-tvos net8.0-tvos was computed.  net8.0-windows net8.0-windows was computed.  net9.0 net9.0 was computed.  net9.0-android net9.0-android was computed.  net9.0-browser net9.0-browser was computed.  net9.0-ios net9.0-ios was computed.  net9.0-maccatalyst net9.0-maccatalyst was computed.  net9.0-macos net9.0-macos was computed.  net9.0-tvos net9.0-tvos was computed.  net9.0-windows net9.0-windows was computed.  net10.0 net10.0 was computed.  net10.0-android net10.0-android was computed.  net10.0-browser net10.0-browser was computed.  net10.0-ios net10.0-ios was computed.  net10.0-maccatalyst net10.0-maccatalyst was computed.  net10.0-macos net10.0-macos was computed.  net10.0-tvos net10.0-tvos was computed.  net10.0-windows net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.2.2 690 9/23/2022
1.2.1 561 8/29/2022
1.2.0 556 8/29/2022
1.1.0 539 8/29/2022
1.0.0 558 8/29/2022