MCPcopy
hub / github.com/danielgtaylor/huma / Negotiate

Method Negotiate

api.go:267–267  ·  view source on GitHub ↗

Negotiate returns the selected content type given the client's `accept` header and the server's supported content types. If the client does not send an `accept` header, then JSON is used.

(accept string)

Source from the content-addressed store, hash-verified

265 // header and the server's supported content types. If the client does not
266 // send an `accept` header, then JSON is used.
267 Negotiate(accept string) (string, error)
268
269 // Transform runs the API transformers on the given value. The `status` is
270 // the key in the operation's `Responses` map that corresponds to the

Callers 1

writeResponseFunction · 0.65

Implementers 1

apiapi.go

Calls

no outgoing calls

Tested by

no test coverage detected