Kvyk.Telegraph 1.0.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package Kvyk.Telegraph --version 1.0.0                
NuGet\Install-Package Kvyk.Telegraph -Version 1.0.0                
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="Kvyk.Telegraph" Version="1.0.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Kvyk.Telegraph --version 1.0.0                
#r "nuget: Kvyk.Telegraph, 1.0.0"                
#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.
// Install Kvyk.Telegraph as a Cake Addin
#addin nuget:?package=Kvyk.Telegraph&version=1.0.0

// Install Kvyk.Telegraph as a Cake Tool
#tool nuget:?package=Kvyk.Telegraph&version=1.0.0                

Kvyk.Telegraph

Simple to use api-client for Telegra.ph.

C# .NET 5.0

How to use

You can find all documentation on Wiki

Quick start

Add using to the top of your file

using Kvyk.Telegraph;
using Kvyk.Telegraph.Models;

Let's create first account

var client = new TelegraphClient();
Account account = await client.CreateAccount(
  "MyFirstAccount",     //Short name
  "I am",               //Author name
  "https://example.com" //Author link
);
client.Token = account.AccessToken; //Your token. Save it to use your account in the future

Now we can create your first page

var nodes = new List<Node>  //Page is an array of nodes
{
  new Node()
  {
    Tag = TagEnum.H3,
    Children = new List<Node>()
    {
      new Node()
      {
        Value = "Test header"
      }
    }
  },
  new Node()
  {
    Tag = TagEnum.P,
    Children = new List<Node>()
    {
      new Node()
      {
        Value = "Hello, World!"
      }
    }
  },
  new Node()
  {
    Tag = TagEnum.Img,
    Artibutes = new TagAttributes()
    {
      Src = "https://telegra.ph/images/logo.png"
    }
  }
};

var page = await client.CreatePage(
  "Test page", //Page title
  nodes
);

var url = page.Url; //Here is your page url

The example of the created page: https://telegra.ph/Test-page-06-07-22

How to help?

This is my first NuGet package, so I'm waiting for a feedback!

Please, tell me about any things I've missed or skiped, any features about code and comments, project description and design of repo. I will be happy to get any feedback.

Use issues or just send me email: kvykmarko@gmail.com

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

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Kvyk.Telegraph:

Package Downloads
Kvyk.Telegraph.Parsers

HTML and Markdown parser for Telegraph library Kvyk.Telegraph You can find all documentation on Wiki (https://github.com/MarkoKvyk/Telegraph/wiki)

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.0 1,379 7/10/2021
1.0.2 929 6/13/2021
1.0.1 829 6/11/2021
1.0.0 818 6/9/2021