MCPcopy Create free account
hub / github.com/PerpetualSoftware/pad / PostStreamWithContentType

Method PostStreamWithContentType

internal/cli/client.go:2074–2077  ·  view source on GitHub ↗

PostStreamWithContentType POSTs a streaming body (typically an *os.File for a multi-GiB bundle import) without buffering the full payload in memory client-side. Mirrors the server's streaming import path — together they keep import memory bounded by the largest single blob (~25 MiB) rather than the

(path string, body io.Reader, contentType string, result interface{})

Source from the content-addressed store, hash-verified

2072// import path — together they keep import memory bounded by the
2073// largest single blob (~25 MiB) rather than the full bundle size.
2074func (c *Client) PostStreamWithContentType(path string, body io.Reader, contentType string, result interface{}) error {
2075 _, err := c.PostStreamWithContentTypeHeaders(path, body, contentType, result)
2076 return err
2077}
2078
2079// PostStreamWithContentTypeHeaders is PostStreamWithContentType, also returning
2080// the response headers.

Callers

nothing calls this directly

Tested by

no test coverage detected