SujaySarma.Sdk.RestApi 6.0.0

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

// Install SujaySarma.Sdk.RestApi as a Cake Tool
#tool nuget:?package=SujaySarma.Sdk.RestApi&version=6.0.0                

SujaySarma.Sdk.RestApi

Provides a way to interact with REST API services. Uses a shared HttpClient and provides methods to GET, PUT, POST, ... and perform all actions normally done using REST API services. There are also classes for different types of common results returned by the service.

This project has no dependencies on anything that is not a part of the .NET Core SDK/runtime. It does not depend on SujaySarma.Sdk.Core either.


Usage

Adds ability to instantiate the client in a number of ways. Two key changes are:

  1. Set the request timeout value. RestApiClient.RequestTimeout property. This is in seconds. You may set different values prior to each call since the property value is attached to the underlying HttpClient on every request.

  2. You can now use non-Json request body types (like form-encoded, etc). But, you need to use the CallApiMethod method. The Get(), Post() and other methods are simply wrappers on this method anyway. When using the CallApiMethod method, use its new contentType parameter to set the desired content type. This defaults to application/json.

Get latest from https://www.nuget.org/packages/SujaySarma.Sdk.RestApi/6.0.0.


Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  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.
  • net6.0

    • No dependencies.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on SujaySarma.Sdk.RestApi:

Package Downloads
SujaySarma.Sdk.RESTClient.Wikipedia

.NET Client for Wikipedia.org REST API. The client will be updated regularly to support all the operations that the REST endpoints support. If you come across missing features or bugs, do open an issue on Github and it will be addressed quickly.

SujaySarma.Sdk.WikipediaApi

.NET Client for Wikipedia.org REST API. The client will be updated regularly to support all the operations that the REST endpoints support. If you come across missing features or bugs, do open an issue on Github and it will be addressed quickly.

SujaySarma.Sdk.Azure.MarketplaceCatalog

Consume the data powering the Azure Portal's Create Resource workflow as an object model. Please follow the instructions at: https://github.com/sujayvsarma/AzureMarketplaceCatalogProvider/blob/master/README.md for using this library.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
8.0.0 99 6/24/2024
6.2.8 359 11/18/2022
6.2.7 409 9/7/2022
6.2.6 403 8/16/2022
6.2.5 559 8/7/2022
6.2.0 525 8/5/2022
6.0.2 657 5/31/2022
6.0.0 458 4/27/2022
2.5.0 548 2/4/2020
1.2.0 499 11/7/2019
1.1.0 931 9/30/2019
1.0.0 613 8/13/2019

Better error handling. For more information, see https://github.com/sujayvsarma/SujaySarma.Sdk.RestApi/ for current information.