MCPcopy
hub / github.com/minio/minio-go / PresignedPutObject

Method PresignedPutObject

api-presigned.go:90–95  ·  view source on GitHub ↗

PresignedPutObject - Returns a presigned URL to upload an object without credentials. URL can have a maximum expiry of upto 7days or a minimum of 1sec.

(ctx context.Context, bucketName, objectName string, expires time.Duration)

Source from the content-addressed store, hash-verified

88// without credentials. URL can have a maximum expiry of upto 7days
89// or a minimum of 1sec.
90func (c *Client) PresignedPutObject(ctx context.Context, bucketName, objectName string, expires time.Duration) (u *url.URL, err error) {
91 if err = s3utils.CheckValidObjectName(objectName); err != nil {
92 return nil, err
93 }
94 return c.presignURL(ctx, http.MethodPut, bucketName, objectName, expires, nil, nil)
95}
96
97// PresignHeader - similar to Presign() but allows including HTTP headers that
98// will be used to build the signature. The request using the resulting URL will

Callers 3

testFunctionalFunction · 0.95
testFunctionalV2Function · 0.95
mainFunction · 0.80

Calls 2

presignURLMethod · 0.95
CheckValidObjectNameFunction · 0.92

Tested by

no test coverage detected