MCPcopy Create free account
hub / github.com/oapi-codegen/oapi-codegen / PostJson

Method PostJson

internal/test/client/client.gen.go:194–204  ·  view source on GitHub ↗
(ctx context.Context, body PostJsonJSONRequestBody, reqEditors ...RequestEditorFn)

Source from the content-addressed store, hash-verified

192}
193
194func (c *Client) PostJson(ctx context.Context, body PostJsonJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
195 req, err := NewPostJsonRequest(c.Server, body)
196 if err != nil {
197 return nil, err
198 }
199 req = req.WithContext(ctx)
200 if err := c.applyEditors(ctx, req, reqEditors); err != nil {
201 return nil, err
202 }
203 return c.Client.Do(req)
204}
205
206func (c *Client) GetJson(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
207 req, err := NewGetJsonRequest(c.Server)

Callers

nothing calls this directly

Calls 3

applyEditorsMethod · 0.95
NewPostJsonRequestFunction · 0.85
DoMethod · 0.65

Tested by

no test coverage detected