Giter Site home page Giter Site logo

phlank / responder Goto Github PK

View Code? Open in Web Editor NEW
5.0 3.0 0.0 388 KB

A C# package for .NET Core 3.1, .NET 5.0, and .NET 6.0 to cleanly build consistent API responses. Available via NuGet.

Home Page: https://www.nuget.org/packages/Phlank.Responder/

License: MIT License

C# 100.00%
aspnetcorewebapi clean-architecture clean-code

responder's Issues

Add tests for ApiResponseBehavior options

These tests need to make sure a new ApiResponseBuilder is generated when none exists and that an existing one only has the InvalidModelStateResponseFactory overridden.

JSON from responder should not interface data

If a response is successful, it should simply return the data to the client, not an object containing the data.

If a response is not successful, it should simply return the error to the client.

The successful property should remain, but shouldn't be serialized.

Design usage for responding with files

Shouldn't deviate too much from the current workflow, though there will likely need to be some deviation.

One option is to allow someone to insert a byte array as content, then use a method like BuildAsFile to create the response. This may return something like a DownloaderResult which would extend the existing ASP.NET Core FileContentResult.

This requires more thought into the workflow and usage of the responder to make it feel as cohesive as it can

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.