Versions in this module Expand all Collapse all v0 v0.1.0 Mar 29, 2022 Changes in this version + const BASE_URL + const MAX_LIMIT_VALUE + const MIN_LIMIT_VALUE + const MIN_SKIP_VALUE + const UPLOAD_URL + var VALID_FILE_TYPES = []string + var VALID_SORT_FIELDS = []string + var VALID_TYPES = []string + type Bool bool + type FileDetails struct + AITags *[]interface{} + CreatedAt *time.Time + CustomCoordinates *String + CustomMetadata *interface{} + EmbeddedMetadata *interface{} + ExtensionStatus map[string]string + FileId *String + FilePath *String + FileType *String + HasAlpha *Bool + Height Int32 + IsPrivateFile *Bool + Mime *String + Name *String + Size Int32 + Tags *[]String + Thumbnail *String + Type *String + UpdatedAt *time.Time + Url *String + Width Int32 + type FileOptions struct + CustomCoordinates *String + CustomMetadata *interface{} + Extensions *[]interface{} + Folder *String + IsPrivateFile *Bool + OverwriteAITags *Bool + OverwriteCustomMetadata *Bool + OverwriteFile *Bool + OverwriteTags *Bool + ResponseFields *[]String + Tags *[]String + UseUniqueFileName *Bool + WebhookUrl *String + func (options FileOptions) ToDict() (fields map[string]string, err error) + func (options FileOptions) ToJSON() (jsonStr string, err error) + type FilesFetchParams struct + FileType *String + Limit *Int32 + Path *String + SearchQuery *String + Skip *Int32 + Sort *String + Tags *[]String + Type *String + func (params FilesFetchParams) BuildURLQuery() (query string, err error) + type ImageKit struct + PrivateKey string + PublicKey string + UrlEndpoint string + func (imgKit *ImageKit) AddTags(fileIds, tags []string) (updatedFileIds []string, err error) + func (imgKit *ImageKit) CopyFile(srcFilePath, destFolderPath string) (err error) + func (imgKit *ImageKit) CreateFolder(folderName, parentFolderPath string) (err error) + func (imgKit *ImageKit) DeleteFile(fileId string) (err error) + func (imgKit *ImageKit) DeleteFiles(fileIds []string) (deletedFileIds []string, err error) + func (imgKit *ImageKit) DeleteFolder(folderPath string) (err error) + func (imgKit *ImageKit) DoRequest(req *http.Request) (body string, err error) + func (imgKit *ImageKit) GetFileDetails(fileId string) (fileDetail *FileDetails, err error) + func (imgKit *ImageKit) GetFiles(params *FilesFetchParams) (fileDetails *[]FileDetails, err error) + func (imgKit *ImageKit) MoveFile(srcFilePath, destFolderPath string) (err error) + func (imgKit *ImageKit) RemoveAITags(fileIds, aiTags []string) (updatedFileIds []string, err error) + func (imgKit *ImageKit) RemoveTags(fileIds, tags []string) (updatedFileIds []string, err error) + func (imgKit *ImageKit) RenameFile(srcFilePath, newFileName string, purgeCache ...bool) (purgeRequestId string, err error) + func (imgKit *ImageKit) UpdateFileDetails(fileId string, options *FileOptions) (fileDetail *FileDetails, err error) + func (imgKit *ImageKit) Upload(file, fileName string, options *FileOptions) (result *FileDetails, err error) + type Int32 int32 + type String string + func (str String) StringInArray(arr []string) bool