tencent cloud

피드백

Setting Hotlink Protection

마지막 업데이트 시간:2024-01-31 17:07:40

    Feature

    This API is used to add hotlink protection (set blocklist/allowlist) for a bucket.

    Request

    Request example

    
    PUT /?hotlink HTTP/1.1
    Host: <BucketName-APPID>.pic.<Region>.myqcloud.com
    Date: GMT Date
    Authorization: Auth String
    Note:
    Authorization: Auth String. For more information, see Request Signature.

    Request headers

    This API only uses common request headers. For more information on common request headers, see Common Request Headers.

    Request body

    The node content of this request body is as follows:
    <Hotlink>
    <Url>xxxxx</Url>
    <Type>black</Type>
    </Hotlink>>
    
    Node Name
    Parent Node
    Description
    Type
    Required
    Url
    Hotlink
    Indicates the domain name address.
    Container
    Yes
    Type
    Hotlink
    Indicates the hotlink protection type. The value white indicates allowlist, the value black indicates blocklist, and the value off indicates the hotlink protection is disabled.
    String
    Yes

    Response

    Response headers

    This API only returns common response headers. For more information, see Common Response Headers.

    Response body

    The response body of this response is empty.

    Use Cases

    Request

    PUT /?hotlink HTTP/1.1
    Host: examplebucket-1250000000.pic.ap-chengdu.myqcloud.com
    Date: Wed, 18 Mar 2000 06:57:54 GMT
    Authorization: XXXXXXXXXXXX
    
    <Hotlink>
    <Url>www.example.com</Url>
    <Type>black</Type>
    </Hotlink>

    Response

    
    HTTP/1.1 200 OK
    Content-Length: 0
    Connection: keep-alive
    Date: Fri, 25 Feb 2017 04:10:22 GMT
    Server: tencent-cos
    x-cos-request-id: NTg3ZjFjMmJfOWIxZjRlXzZmNDhf****
    
    문의하기

    고객의 업무에 전용 서비스를 제공해드립니다.

    기술 지원

    더 많은 도움이 필요하시면, 티켓을 통해 연락 바랍니다. 티켓 서비스는 연중무휴 24시간 제공됩니다.

    연중무휴 24시간 전화 지원