HeadObject
    • PDF

    HeadObject

    • PDF

    Article summary

    Available in Classic and VPC

    View object headers based on the specified headers. No request query parameter or request body is used in the operation.

    Requests

    The following describes the request format for the endpoint. The request format is as follows.

    MethodURI
    HEAD/{bucket-name}/{object-name}

    Request syntax

    The request syntax is as follows.

    HEAD https://{endpoint}/{bucket-name}/{object-name} # path style
    HEAD https://{bucket-name}.{endpoint}/{object-name} # virtual host style
    

    Request headers

    The following describes the HeadObject header. For headers common to all Object Storage APIs, see Object Storage common request headers.

    FieldTypeRequiredDescription
    rangeStringOptionalReturn the size of the object in bytes within a specified range
    if-matchStringOptionalReturn the object if the specified ETag string matches the source object
    if-none-matchStringOptionalReturn the object if the specified ETag string is different from the source object
    if-unmodified-sinceStringOptionalReturn the object if the source object hasn't been edited since the specified date
    • Must be in a valid date format
      • <Example> Wed, 30 Nov 2016 20:21:38 GMT
    if-modified-sinceStringOptionalReturn the object if the source object was edited after the specified date
    • Must be in a valid date format
      • <Example> Wed, 30 Nov 2016 20:21:38 GMT

    Request path parameters

    The following describes the parameters.

    FieldTypeRequiredDescription
    bucket-nameStringRequiredName of the bucket to view object headers in
    object-nameStringRequiredName of the object whose headers you want to view

    Request example

    The following is a sample request.

    HEAD /example-bucket/soldier-bee HTTP/1.1
    Authorization: {authorization-string}
    x-amz-date: 20160825T183244Z
    Host: kr.object.ncloudstorage.com
    

    Responses

    The following describes the response format.

    Response headers

    For response headers common to all Object Storage APIs, see Object Storage common response headers.

    Response status codes

    For response status codes common to all Object Storage APIs, see Object Storage response status codes.

    Response example

    The following is a sample response.

    HTTP/1.1 200 OK
    Date: Thu, 25 Aug 2016 18:32:44 GMT
    Accept-Ranges: bytes
    x-amz-request-id: da214d69-1999-4461-a130-81ba33c484a6
    ETag: "37d4c94839ee181a2224d6242176c4b5"
    Content-Type: text/plain; charset=UTF-8
    Last-Modified: Thu, 25 Aug 2016 17:49:06 GMT
    Content-Length: 11
    

    Was this article helpful?

    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.