Introduction

Last updated: 2021-03-22 15:12:21

    Tencent COS uses XML APIs, which are lightweight, connectionless, and stateless. By calling XML APIs, you can send requests and receive responses directly over HTTP/HTTPS to interact with the COS backend.

    COS adopts a data transfer framework different from that of Tencent Cloud. Therefore, APIs and SDKs of COS are independent. For more information, please see the Operation List of COS APIs, or download the desired SDKs from SDK Overview. Note that the guides of Tencent Cloud APIs and the corresponding SDKs do not cover the operations of COS.

    Note:

    • By using COS APIs, you acknowledge that you have read and agree to the General Service Level Agreements and Tencent COS Service Level Agreement.
    • For more information about the available regions of COS, please see Regions and Access Endpoints.
    • Before using APIs or SDKs to initiate a request, you are advised to read the Creating Request Overview document to learn more about access endpoints, authentication, and how to determine access via a private or public network.
    • If you want to receive responses in JSON format, you are advised to configure in the COS SDK.
    • For API formats of other Tencent Cloud services, please see APIs.

    API Overview

    For more information about the APIs supported by COS, please see Operation List.

    You are advised to use API Explorer.
    Click to debug
    API Explorer makes it easy for you to make online API calls, verify signatures, generate SDK code, and search for the desired APIs. You can also use it to query the content of each request as well as its response, and obtain the auto-generated SDK calling samples.

    COS Glossary

    Terms and concepts you may see when using the APIs are described as follows:

    Name Description
    APPID A unique user-level resource identifier for COS access. It can be obtained at Manage API Key.
    SecretId A developer-owned ID used for the project. It can be obtained at Manage API Key.
    SecretKey A developer-owned secret key used for the project. It can be obtained at Manage API Key.
    Bucket A container used for data storage. For more information, please see Bucket Overview.
    Object A file stored in COS. It is the basic entity that is stored.
    ObjectKey A unique identifier of an object stored in COS. For more information about objects and object keys, please see Object Overview.
    Region Region information. For more information about the enumerated values (such as ap-beijing, ap-hongkong, and eu-frankfurtplease), please see Regions and Access Endpoints.
    ACL Access Control List, a list of access control information for a specified bucket or object.
    CORS Cross-origin resource sharing
    This refers to the HTTP requests for resources from a different endpoint.
    Multipart Uploads An upload mode provided by Tencent Cloud COS.
    Object Content Binary of the uploaded files.

    Getting Started

    To use the Tencent COS APIs, take the following steps:

    1. Activate COS in the COS console.
    2. Create a bucket in the COS console.
    3. In the CAM console, obtain APPID at Manage API Key. Then, create SecretId and SecretKey.
    4. Write a request signature algorithm program (or use any server SDK). For more information, please see Request Signature.
    5. Calculate the signature and call APIs to perform operations.