requestCdnPlusPurge
    • PDF

    requestCdnPlusPurge

    • PDF

    Article summary

    Overview

    Requests CDN+ purge.

    Request

    Request parameters

    ParameterRequiredTypeLimitationsDescription
    cdnInstanceNoYStringCDN instance number
    isWholeDomainYBooleantrue or falseIndicates whether to purge all domains.
    Enter true for purge requests for the entire domain, false for purge requests for the specific domain.
    domainIdList.NNList<String>List of domain IDs
    Enter for purge requests for a specific domain.
    ex) domainIdList.1=CD000000000000016682&domainIdList.2=CD000000000000016683
    isWholePurgeYBooleantrue or falseIndicates whether to purge all content.
    Enter true for purge requests for all files or false for purge requests for specific directories or files.
    targetFileList.NNList<String>List of files to purge
    Enter for purge request of a specific file.
    ex) targetFileList.1=alice.txt&targetFileList.2=bob.png
    targetDirectoryNameNStringName of the directory to purge
    Enter for purge requests from a specific directory. All files under that directory will be purged.
    ex) targetDirectoryName=/contents/sample
    responseFormatTypeNStringJSON or XMLResponse type

    Response

    The API returns an HTTP status code indicating success or failure.

    HTTP status codeCode messageDescription
    200SuccessPurge succeeded
    401UnauthorizedAuthentication failed
    500Internal Server ErrorServer error

    Properties

    PropertyRequiredTypeDescription
    cdnInstanceNoNStringCDN instance number
    purgeIdNStringPurge ID
    isWholePurgeNBooleanIndicates whether to purge all content.
    isWholeDomainNBooleanIndicates whether to purge all domains.
    cdnPlusServiceDomainListNList<CdnPlusServiceDomain>List of CDN+ service domains
    domainIdNStringDomain ID
    serviceDomainTypeCodeNStringService domain type code
    protocolTypeCodeNStringProtocol type code
    defaultDomainNameNStringDefault domain name
    userDomainNameNStringUser domain name
    targetDirectoryNameNStringTarget directory name
    targetFileListNList<String>List of files to purge
    requestDateNStringRequest date
    purgeStatusNameNStringPurge status

    Examples

    Request example

    https://ncloud.apigw.ntruss.com/cdn/v2/requestCdnPlusPurge?cdnInstanceNo=711484&isWholePurge=true&isWholeDomain=true&responseFormatType=XML
    

    Response example

    <?xml version="1.0" encoding="UTF-8"?>
    <requestCdnPlusPurgeResponse>
      <requestId>337bd4f2-5bdf-4707-98f5-216c3ee79395</requestId>
      <returnCode>0</returnCode>
      <returnMessage>success</returnMessage>
      <totalRows>1</totalRows>
      <cdnPlusPurgeHistoryList>
        <cdnPlusPurgeHistory>
          <cdnInstanceNo>711484</cdnInstanceNo>
          <purgeId>PT000000000000015497</purgeId>
          <isWholePurge>true</isWholePurge>
          <isWholeDomain>true</isWholeDomain>
          <cdnPlusServiceDomainList>
            <cdnPlusServiceDomain>
              <domainId>CD000000000000008054</domainId>
              <serviceDomainTypeCode>DEFAULT</serviceDomainTypeCode>
              <protocolTypeCode>HTTP</protocolTypeCode>
              <defaultDomainName>sjktsyeuckvp711484.cdn.ntruss.com</defaultDomainName>
              <userDomainName></userDomainName>
            </cdnPlusServiceDomain>
          </cdnPlusServiceDomainList>
          <targetDirectoryName></targetDirectoryName>
          <targetFileList/>
          <requestDate>2018-12-09T02:00:18+0900</requestDate>
          <purgeStatusName>ready</purgeStatusName>
        </cdnPlusPurgeHistory>
      </cdnPlusPurgeHistoryList>
    </requestCdnPlusPurgeResponse>
    

    Error codes

    Error codeDescription
    29200Invalid CDN rule.
    29201Cannot operate this CDN service. Please check status.
    29202Invalid CDN purge request.
    29203Invalid CDN service domain type code.
    29204Invalid CDN instance.
    29205Unable to control the CDN service because this CDN service is for Live Transcoder.
    29211An error occurred while creating CDN service.
    29215This CDN service cannot request purge with partial domains.
    29216Invalid CDN service domain.
    29209The certificate cannot register for CDN.
    29217Please enter target file list or directory.
    29218Please select target service domains.
    29221Unable to control the CDN service because this CDN service is for Image Optimizer.
    29222Invalid image optimizer instance number.
    29223Cache Key Hostname cannot be set Origin Hostname if there is only one service domain.
    29224Cache Key Hostname cannot be set Origin Hostname if use CDN domain.

    Was this article helpful?

    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.