api/internal/interfaces/mediaStorage.go
2025-10-15 19:44:41 +03:00

15 lines
406 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package interfaces
import (
"context"
"io"
"net/url"
"time"
)
type MediaStorage interface {
СreateBucketIfNotExists(bucketName string) error
Upload(ctx context.Context, bucket, object string, reader io.Reader, size int64) error
Get(ctx context.Context, bucket, object string, expires time.Duration, params url.Values) (*url.URL, error)
Delete(ctx context.Context, bucket, object string) error
}