ScriptCs.EasyHttp
0.3.2
See the version list below for details.
dotnet add package ScriptCs.EasyHttp --version 0.3.2
NuGet\Install-Package ScriptCs.EasyHttp -Version 0.3.2
<PackageReference Include="ScriptCs.EasyHttp" Version="0.3.2" />
paket add ScriptCs.EasyHttp --version 0.3.2
#r "nuget: ScriptCs.EasyHttp, 0.3.2"
// Install ScriptCs.EasyHttp as a Cake Addin #addin nuget:?package=ScriptCs.EasyHttp&version=0.3.2 // Install ScriptCs.EasyHttp as a Cake Tool #tool nuget:?package=ScriptCs.EasyHttp&version=0.3.2
Using this script pack you can write very simple scripts similar to this:
public class Notification
{
public string Message {get; set;}
public string SenderName {get; set;}
}
var notificationToSend = new Notification { Message = "Merry christmas!", SenderName = "Santa"};
var http = Require<EasyHttp>();
var result = http.PostJson("http://your.site.com/api/notification", notificationToSend);
Console.WriteLine("Response status code: " + result.StatusCode);
The script pack also has the Json.NET namespace available so you can make use of different Json.NET serialization possibilities (e.g. [JsonIgnore]) to suit your needs.
Source code can be found at https://github.com/martinobrink/ScriptCs.EasyHttp.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net45 is compatible. net451 was computed. net452 was computed. net46 was computed. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
-
.NETFramework 4.5
- Microsoft.Net.Http (>= 2.2.18)
- Newtonsoft.Json (>= 5.0.8)
- ScriptCs.Contracts (>= 0.8.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.