Example Programs

OBS Python SDK provides abundant example programs for user reference and direct use. These programs can be obtained from the OBS Python SDK development package. For example, files in eSDK_Storage_OBS_<versionId>_Python/examples obtained by decompressing eSDK_Storage_OBS_<versionId>_Python.zip are example programs. Alternatively, you can click code package names provided in the following table to obtain corresponding example programs.

Example programs include:

Sample Code

Description

bucket_operations_sample

How to use bucket-related APIs.

object_operations_sample

How to use object-related APIs.

download_sample

How to download an object.

create_folder_sample

How to create a folder.

delete_objects_sample

How to delete objects in a batch.

list_objects_sample

How to list objects.

list_versions_sample

How to list versioning objects.

list_objects_in_folder_sample

How to list objects in a folder.

object_meta_sample

How to customize object metadata.

simple_multipart_upload_sample

How to perform a multipart upload.

restore_object_sample

How to download Archive objects.

concurrent_copy_part_sample

How to concurrently copy parts of a large object.

concurrent_download_object_sample

How to concurrently download parts of a large object.

concurrent_upload_part_sample

How to concurrently upload parts of a large object.

post_object_sample

How to perform a browser-based upload.

temporary_signature_sample

How to use URLs for authorized access.