All Projects → DalSoft → Dalsoft.restclient

DalSoft / Dalsoft.restclient

Licence: mit
The C# REST Client - the only REST/ HTTP Client you will ever need

Programming Languages

csharp
926 projects

Projects that are alternatives of or similar to Dalsoft.restclient

Json Flatfile Datastore
Simple JSON flat file data store with support for typed and dynamic data.
Stars: ✭ 212 (+14.59%)
Mutual labels:  json, dynamic
Restclient
🦄 Simple HTTP and REST client for Unity based on Promises, also supports Callbacks! 🎮
Stars: ✭ 675 (+264.86%)
Mutual labels:  rest-client, json
Dotnet Fake Json Server
Fake JSON Server is a Fake REST API that can be used as a Back End for prototyping or as a template for a CRUD Back End.
Stars: ✭ 265 (+43.24%)
Mutual labels:  json, dynamic
Natasha
基于 Roslyn 的 C# 动态程序集构建库,该库允许开发者在运行时使用 C# 代码构建域 / 程序集 / 类 / 结构体 / 枚举 / 接口 / 方法等,使得程序在运行的时候可以增加新的模块及功能。Natasha 集成了域管理/插件管理,可以实现域隔离,域卸载,热拔插等功能。 该库遵循完整的编译流程,提供完整的错误提示, 可自动添加引用,完善的数据结构构建模板让开发者只专注于程序集脚本的编写,兼容 stanadard2.0 / netcoreapp3.0+, 跨平台,统一、简便的链式 API。 且我们会尽快修复您的问题及回复您的 issue.
Stars: ✭ 705 (+281.08%)
Mutual labels:  dotnetcore, dynamic
Restc Cpp
Modern C++ REST Client library
Stars: ✭ 371 (+100.54%)
Mutual labels:  rest-client, json
Restclient.net
.NET REST Client Framework for all platforms
Stars: ✭ 143 (-22.7%)
Mutual labels:  rest-client, json
Dynamic walls App
🌘 The Dynamic_Walls scripts replicating macOS Mojave's dynamic wallpaper feature combined into an app
Stars: ✭ 180 (-2.7%)
Mutual labels:  dynamic
Feed Module
Everyone deserves RSS, ATOM and JSON feeds!
Stars: ✭ 182 (-1.62%)
Mutual labels:  json
Jsome
✨ Make your JSON look AWESOME
Stars: ✭ 179 (-3.24%)
Mutual labels:  json
Json Stringify Pretty Compact
The best of both `JSON.stringify(obj)` and `JSON.stringify(obj, null, indent)`.
Stars: ✭ 177 (-4.32%)
Mutual labels:  json
Sparkliner
Sparkliner — easy way to make sparkline graph [Sketch plugin]
Stars: ✭ 184 (-0.54%)
Mutual labels:  json
License List Data
Various data formats for the SPDX License List including RDFa, HTML, Text, and JSON
Stars: ✭ 182 (-1.62%)
Mutual labels:  json
Json C
https://github.com/json-c/json-c is the official code repository for json-c. See the wiki for release tarballs for download. API docs at http://json-c.github.io/json-c/
Stars: ✭ 2,313 (+1150.27%)
Mutual labels:  json
Bancosbrasileiros
Lista de bancos brasileiros | Brazilian banks list
Stars: ✭ 178 (-3.78%)
Mutual labels:  json
Rafty
Implementation of RAFT consensus in .NET core
Stars: ✭ 182 (-1.62%)
Mutual labels:  dotnetcore
Play Json Derived Codecs
Stars: ✭ 179 (-3.24%)
Mutual labels:  json
Stubbornjava
Unconventional Java code for building web servers / services without a framework. Think dropwizard but as a seed project instead of a framework. If this project had a theme it would be break the rules but be mindful of your decisions.
Stars: ✭ 184 (-0.54%)
Mutual labels:  json
Jsons
🐍 A Python lib for (de)serializing Python objects to/from JSON
Stars: ✭ 178 (-3.78%)
Mutual labels:  json
Zson
专为测试人员打造的JSON解析器
Stars: ✭ 181 (-2.16%)
Mutual labels:  json
Application Insights Workbooks
Templates for Azure Monitor Workbooks
Stars: ✭ 180 (-2.7%)
Mutual labels:  json

DalSoft C# RestClient

If you find this repo / package useful please star it.

Nuget Help and chat on Gitter StackOverflow Docs

For everything you need to know, please head over to https://restclient.dalsoft.io

👉 New Static Typing and Resource Expressions in 4.0

alt text

Just some of the things you can do with DalSoft.RestClient

Supported Platforms

RestClient targets .NET Standard 2.0 therefore supports Windows, Linux, Mac and Xamarin (iOS, Android and UWP).

If you need to target .NET Standard 1.4 use version 3.2.2.

Getting Started

Install via .NET CLI

> dotnet add package DalSoft.RestClient

Install via NuGet

PM> Install-Package DalSoft.RestClient

Example calling a REST API

You start by new'ing up the RestClient and passing in the base uri for your RESTful API.

For example if your wanted to perform a GET on https://jsonplaceholder.typicode.com/users/1 you would do the following:

Static Typed Rest Client

For the Static typed Rest Client just pass a string representing the resource you want access to the Resource method, and then call the HTTP method you want to use.

var client = new RestClient("https://jsonplaceholder.typicode.com");

User user = await client.Resource("users/1").Get();
   
Console.WriteLine(user.Name);

Dynamicaly Typed Rest Client

For the Dynamicaly typed Rest Client chain members that would make up the resource you want to access - ending with the HTTP method you want to use.

dynamic client = new RestClient("https://jsonplaceholder.typicode.com");

var user = await client.Users(1).Get();
   
Console.WriteLine(user.name);

Note all HTTP methods are async

Recent Releases

About

RestClient is a very lightweight wrapper around System.Net.HttpClient that uses the dynamic features of .NET 4 to provide a fluent way of accessing RESTFul API's, making it trivial to create REST requests using a lot less code.

Originally created to remove the boilerplate code involved in making REST requests using code that is testable. I know there are a couple of REST clients out there but I wanted the syntax to look a particular way with minimal fuss.

RestClient is biased towards posting and returning JSON - if you don't provide Accept and Content-Type headers then they are set to application/json by default See Working with non JSON content.

Standing on the Shoulders of Giants

DalSoft.RestClient is built using the following great open source projects:

DalSoft.RestClient is inspired by and gives credit to:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].