using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CoAP;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            // create a new client
            CoapClient client = new CoapClient();

            // set the Uri to visit
            client.Uri = new Uri("coap://localhost/helloworld");

            // now send a GET request to say hello~
            Response response = client.Get();

            Console.WriteLine(response.PayloadString);  // Hello World!

            Console.WriteLine("Press any key to exit.");
            Console.ReadKey();

        }
    }
}
