tencent cloud

Smart Media Hosting

Deleting a Single File

다운로드
포커스 모드
폰트 크기
마지막 업데이트 시간: 2026-01-07 10:49:06

Introduction

This document provides an API overview about deleting files and SDK sample code.
API
Operation Description
Deletes files.

SDK API Reference

For specific parameters and method descriptions of all SDK APIs, please see SDK API Reference.

Deletes files.

Feature Description

Used to delete files.

Sample Code

QCloudSMHDeleteFileRequest * request = [QCloudSMHDeleteFileRequest new];
request.libraryId = @"libraryId";
request.spaceId = @"spaceId";
request.filePath = @"test.jpg";
// When the media library enables the recycle bin, this parameter specifies whether to permanently delete the file or move it to the Recycle Bin. 1: permanently delete, 0: move to Recycle Bin. Default is 0.
request.permanent = 0;
[request setFinishBlock:^(id _Nullable outputObject, NSError * _Nullable error) {

}];
[[QCloudSMHService defaultSMHService] deleteFile:request];


도움말 및 지원

문제 해결에 도움이 되었나요?

피드백