MCPcopy Index your code
hub / github.com/go-chi/render

github.com/go-chi/render @v1.0.3

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.0.3 ↗ · + Follow
32 symbols 62 edges 4 files 25 documented · 78% 17 cross-repo links
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

render

tests Go Report Card Go Reference

The render package helps manage HTTP request / response payloads.

Every well-designed, robust and maintainable Web Service / REST API also needs well-defined request and response payloads. Together with the endpoint handlers, the request and response payloads make up the contract between your server and the clients calling on it.

Typically in a REST API application, you will have your data models (objects/structs) that hold lower-level runtime application state, and at times you need to assemble, decorate, hide or transform the representation before responding to a client. That server output (response payload) structure, is also likely the input structure to another handler on the server.

This is where render comes in - offering a few simple helpers and interfaces to provide a simple pattern for managing payload encoding and decoding.

We've also combined it with some helpers for responding to content types and parsing request bodies. Please have a look at the rest example which uses the latest chi/render sub-pkg.

All feedback is welcome, thank you!

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Function 24
Method 3
Interface 2
TypeAlias 2
Struct 1

Languages

Go100%

Modules by API surface

render.go12 symbols
responder.go11 symbols
content_type.go5 symbols
decoder.go4 symbols

For agents

$ claude mcp add render \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page