Tiny.RestClient icon indicating copy to clipboard operation
Tiny.RestClient copied to clipboard

Add support of cookie

Open jgiacomini opened this issue 6 years ago • 2 comments

  • Add cookies un requests
  • Read cookies in ouput
  • Cookie container for all request

jgiacomini avatar Aug 20 '18 14:08 jgiacomini

Hey @jgiacomini , about this issue, Are you still up for it ?

An effective way to achieve this (in my opinion) is to create a Response<T> class that implements the generic interface below to cater for all types of responses and their respective cookies except ExecuteAsHttpResponseMessageAsync (since the cookies can be gotten from the HttpResponseMessage drectly). The headers are added to cater for your Issue 1 as well. What do you think ?

interface IResponse<T> {
   Headers headers { get; }
   Cookies Cookies { get; }
   T Content { get; }
}

yemikudaisi avatar Nov 06 '21 01:11 yemikudaisi

Hello @yemikudaisi, If you can help to add this feature on the package it will be really appreciated.

I am working on the v2.0 which remove the dependency to Newtonsoft and use System.Text.Json. I am also working to remove all the unnecessary memory allocations to have the fastest rest API client

jgiacomini avatar Oct 31 '22 13:10 jgiacomini