Hello comunity π
I built DevToAPI - a simple .NET library that implements the Forem/Dev.to API. At the moment, all endpoints are implemented.
I hope it will be useful ;)
Usage examples:
Create new article
var client = new DevToClient("api-key"); await client.Articles.CreateAsync(new CreateArticle() { Title = "My post", BodyMarkdown = "...", Tags = new List<string>() { "csharp", "opensource" }, Published = true });
Pagination
var client = new DevToClient("api-key"); var pagination = await client.Articles.GetAllMyAsync(); while (pagination.CanMoveNext) { var myArticles = pagination.Items; //do stuff await pagination.NextPageAsync(); }
Specific page
var client = new DevToClient("api-key"); var pagination = await client.Articles.GetAllMyAsync(option => { option.Page = 5; option.PageSize = 10; });
Supported Platforms
.NET 4.5.2 or greater
.NET Standard 2.0 or greater
Top comments (0)