All Documents
Current Document

Content is empty

If you don't find the content you expect, please try another search term

Documentation

Usage notes

Last updated:2021-03-17 10:51:40

Usage notes

Case conventions

A variable or action name starts with a capital letter and follows the CamelCase naming convention.
A value of an enumeration type is generally written in full lower case with underscores (_) in between or in full upper case, without specific conventions.

Time format

The time follows the ISO 8601 standard in the YYYY-MM-DDThh:mm+0800 format. The time is displayed in UTC+8. Example: 2016-08-01T21:14+0800.

Enumeration types

DomainStatus

Domain name states include:

  • online
  • offline
  • configuring
  • configure_failed
  • icp_checking
  • icp_check_failed
  • locked
  • locking

CdnSubType

Business subtypes include:

  • download
  • video
  • live
  • page

CacheRuleType

Cache policy types include:

  • file_suffix: the file name extension. Separate multiple file name extensions with commas (,), for example, jpg,txt,mp4.
  • directory: the directory. You can specify only one directory at a time, which must start and end with a slash (/), for example, /www/dir/aaa/. To set all directories under a domain name, enter a slash (/).
  • exact: the exact path. You can specify only one path at a time, which must start with a slash (/), for example, /www/dir/aaa.

ErrorHttpCode

The following error codes are supported.

HTTP status code Description
400 The server failed to interpret the client request due to invalid syntax.
403 The server successfully interpreted the client request but refused to respond to it.
404 The server failed to find resources based on the client request.
405 The method in the client request was prohibited.
406 The server failed to fulfill the client request based on the content of the client request.
414 The server failed to process the request URI, which is usually a website URL, because it was too long.
416 The range specified by the client request was invalid.
500 The server failed to fulfill the request due to an internal error.
501 The server does not support the feature required to fulfill the request.
502 The server that acts as a gateway or proxy received an invalid response from the remote server for the request.
503 The server temporarily failed to respond to the client request due to overload or system maintenance.
504 The server that acts as a gateway or proxy failed to obtain the request from the remote server in time.

Content-Type

By default, intelligent compression supports the following content types:

  • application/atom+xml

  • application/javascript

  • application/x-javascript

  • application/xhtml+xml

  • application/xml

  • application/xml+rss

  • application/xml-dtd

  • text/css

  • text/htm

  • text/html

  • text/javascript

  • text/js

  • text/json

  • text/plain

  • text/xml

  • application/json

  • application/x-font-ttf

  • image/svg+xml

Regions

Regions include:

  • CN: Mainland China
  • HK: Hong Kong, China
  • TW: Taiwan, China
  • AS: other parts of Asia
  • NA: North America
  • EU: Europe
  • AU: Oceania
  • AF: Africa
  • SA: South America

Provinces

Provinces include:

  • beijing, neimenggu, shanxi, hebei, and tianjin
  • ningxia, shaanxi, gansu, and qinghai
  • heilongjiang, jilin, and liaoning
  • fujian, jiangsu, anhui, shandong, shanghai, and zhejiang
  • henan, hubei, jiangxi, and hunan
  • guizhou, yunnan, chongqing, and sichuan
  • guangdong, guangxi, and hainan

Isps

ISPs include:

  • UN: China Unicom
  • CM: China Mobile
  • CT: China Telecom
  • CTT: China Tietong
  • PBS: Dr. Peng
  • CE: CERNET
  • Other
  • OverseaIsp

Areas

Areas include:

  • beijing, neimenggu, shanxi, hebei, and tianjin
  • ningxia, shaanxi, gansu, qinghai, and xinjiang
  • heilongjiang, jilin, and liaoning
  • fujian, jiangsu, anhui, shandong, shanghai, and zhejiang
  • henan, hubei, jiangxi, and hunan
  • guizhou, yunnan, chongqing, sichuan, and xizang
  • guangdong, guangxi, and hainan
  • hongkong, macao, and taiwan
  • other
  • oversea

Error codes

The following table describes the errors for the HTTP status code 400, including the error codes, error messages, and description.

HTTP status code Error code Error message Description
400 InvalidClientTokenId The security token included in the request is invalid. The error message returned because the AccessKeyID or SecretAccessKey is invalid.
400 UnSupportCdnType This api currently did not support such cdn type. Supported:file. The error message returned because the business type is not supported. Only the specified type is supported.
400 InvalidCdnType Invalid cdn type.Expected:file\live\page\download, but receive:${CdnType} The error message returned because the business type is invalid.
400 InvalidGranularity Invalid granularity.Option for granularity is 5, 10, 15 ...1440(min),received:${Granularity} The error message returned because the statistical granularity is invalid.
400 InvalidDataType.EdgeOrigin Invalid data type.Expected:edge\origin, but receive:${DataType} The error message returned because the data type is invalid.
400 InvalidDataType.ReqhitrateFlowhitrate Invalid data type.Expected:reqhitrate\flowhitrate, but receive:${DataType} The error message returned because the hit rate data type is invalid.
400 InvalidResultType Invalid result type.Expected:0\1, but receive:${ResultType} The error message returned because the result type is invalid.
400 InvalidRegion Invalidregion.Expected:CN,NA,AS,EU,SA,AU,AF, but receive:${Region} The error message returned because the region is invalid.
400 InvalidEndTime.Mismatch Specified end time should not be earlier than starttime."StartTime:${StartTime},EndTime:${EndTime} The error message returned because the end time is earlier than the start time.
400 InvalidStartTime.ValueNotSupported The gap between start time and end time should be less then or equal to 93 days."StartTime:${StartTime} , EndTime:${EndTime} The error message returned because the interval between the start time and the end time is greater than 93 days.
400 InvalidStartTime.Malformed Specified start time is malformed."StartTime:${StartTime}" The error message returned because the start time is invalid.
400 InvalidEndTime.Malformed Specified end time is malformed."EndTime:${EndTime}" The error message returned because the end time is invalid.
400 InvalidDomain.NotFound The domain provided does not belong to you.Invalid domains:${DomainId} The error message returned because the domain name does not belong to you.
400 InvalidDomain.Offline The domain provided is offline.Invalid domains:${DomainId} The error message returned because the domain name is offline.
400 IllegalOperation Your account does not open CDN service yet The error message returned because you have not activated Kingsoft Cloud CDN.
400 TooManyDataPoints "Domain number: ${DomainNumber}, region number:${RegionNumber}, time points:${TimePoints}, total points in this request(DomainNumber _RegionNumber_TimePoints):${TotalPoints}.Total points must be less than or equal to 10000." The error message returned because the throughput exceeds the upper limit of the API operation.
400 NoAvailableDomain Your do not have any domain config yet The error message returned because no domain name is available.
400 DomainCdnTypeNotMatch Domains and cdn type did not match.Invalid domains:${DomainId} The error message returned because the domain name does not match the business type.
400 BindException Rejected keys and values: ${params};${paramValues} The error message returned because the parameters are invalid.
400 InvalidCdnSubType Sub type is malformed The error message returned because the business subtype is invalid.
400 InvalidOriginProtocol Back to the source protocol is malformed The error message returned because the back-to-origin protocol is invalid.
400 InvalidCdnProtocol Edge node protocol is malformed The error message returned because the access protocol is invalid.
400 InvalidOriginType Source station type is malformed The error message returned because the origin type is invalid.
400 InvalidOriginPort Invalid origin port.Expected:80, but receive: $(OriginPort) The error message returned because the back-to-origin port is invalid.
400 InvalidCacheRuleType Invalid cache rule type.Expected:file_suffix\directory\exact\url_regex, but receive:$(value) The error message returned because the cache policy type is invalid.
400 InvalidCacheRuleValue Invalid cache rule value.Expected:$(type) value, but receive: $(value) The error message returned because the cache policy value is invalid.
400 InvalidCacheTime Invalid cache time value.Expected:Must be lost as an integer must be greater than 0, but receive: $(value) The error message returned because the cache time value is invalid.
400 InvalidSwitchValue Invalid switch value.Expected:on\off, but receive:$(value) The error message returned because the switch value is invalid.
400 CacheRuleListIsEmpty Cache rule list is empty. The error message returned because the cache policy list is empty.
400 InvalidConfigInfoQueryCondition Invalid configuration information query condition.Expected: cache_expired\cc\error_page\ http_header\optimize\page_compress\ignore_query _string\range\referer\req_auth\src_host\video_seek\ waf\notify_url\redirect_type, but receive: $(value) The error message returned because the configuration query condition is invalid.
400 RequiresInputValue Requires input value.Expected:This value is required, but no found value from: $(value) The error message returned because an input value is required.
400 InvalidSourceStationLine Invalid source station line.Expected:default\un\ct\cm, but receive:$(value) The error message returned because the origin line is invalid.
400 InvalidSourceStationType Invalid source station type.Expected:ipaddr\domain, but receive:$(value) The error message returned because the origin type is invalid.
400 InvalidDomainName This value does not conform to the rules of the domain name.Expected: Submit parameter values in the format, but receive:$(value) The error message returned because the value does not conform to the rules of the domain name.
400 InvalidCdnSubType.Live Invalid live child type.Expected:live, but receive:$(value) The error message returned because the live subtype is invalid.
400 InvalidCdnSubType.Download Invalid download child type.Expected:web\download\video, but receive:$(value) The error message returned because the download subtype is invalid.
400 InvalidCdnProtocol.Live Invalid live protocol.Expected:http+flv\hls\rtmp, but receive:$(value) The error message returned because the live protocol is invalid.
400 InvalidCdnProtocol.Download Invalid download protocol.Expected:HTTP, but receive:$(value) The error message returned because the download protocol is invalid.
400 InvalidOriginType Invalid origin type.Expected:ipaddr\domain\ksvideo\KS3, but receive:$(value) The error message returned because the origin type is invalid.
400 InvalidOriginType.Live Invalid live origin type.Expected:ipaddr\domain\ksvideo, but receive:$(value) The error message returned because the live origin type is invalid.
400 InvalidOriginType.Download Invalid Download origin type.Expected:ipaddr\domain\KS3, but receive:$(value) The error message returned because the download origin type is invalid.
400 InvalidOriginProtocol.Live Invalid live origin protocol.Expected:rtmp, but receive:$(value) The error message returned because the live back-to-origin protocol is invalid.
400 InvalidOriginProtocol.Download Invalid download origin protocol.Expected:http, but receive:$(value) The error message returned because the download back-to-origin protocol is invalid.
400 InvalidOriginPort Invalid origin port.Expected:80, but receive:$(value) The error message returned because the back-to-origin port is invalid.
400 PageSizeOutOfRange Page size out of range.Expected:Between 1 and 500, but receive:$(value) The error message returned because the page size is out of range.
400 pageNumberOutOfRange Page number out of range. Expected:Between 1 and 10000, but receive:$(value) The error message returned because the page number is out of range.
400 InvalidDomainStatus Invalid domain status.Expected:online\offline\configuring\configure _failed\icp_checking\icp_check_failed, but receive:$(value) The error message returned because the status of the domain name is invalid.
400 InvalidActionType Invalid domain action type.Expected:start\stop, but receive:$(value) The error message returned because the domain action type is invalid.
400 InvalidOriginAddress Origin address is not standardized. The error message returned because the origin address is invalid.
400 OriginLineRepeat Origin line can not be repeated. The error message returned because the origin line already exists.
400 OriginTypeNotUnique Advanced source station must unique. The error message returned because the back-to-origin type must be unique.
400 InvalidOriginPolicyType Invalid polling type.Expected:rr\quality, but receive:$(value) The error message returned because the round robin type is invalid.
400 PolicyBestCountOutOfRange Policy best count out of range.Expected:Between 1 and 10, but receive:$(value) The error message returned because the count is out of range.
400 NotCorrectURL URL is not correct. The error message returned because the URL is incorrect.
400 InvalidReferType Invalid refer type.Expected:block\allow, but receive:$(value) The error message returned because the referer type is invalid.
400 TooManyReferList Too many refer url in this request.Expected:Between 1 and 100, but receive:$(value) The error message returned because the request contains too many URLs.
400 DomainNameHasBeUsed Domain name has been used. The error message returned because the domain name already exists.
400 DomainNotFound Through the domain name ID did not find the domain name information. The error message returned because no domain name is found.
400 RecordQueryFailed Query record information failed. The error message returned because no ICP filing information is found for the domain name.
400 StatusCannotOrNoneedModified Current domain status does not allow or need to be modified. The error message returned because the current status cannot or does not need to be modified.
400 CanNotSetByOriginType Cannot set back the source host function Because of OringType value is KS3 The error message returned because the back-to-origin host cannot be modified when the origin type is KS3.
400 RepeatedCacheValue The value of the same CacheRuleType cannot be repeated. The error message returned because the value of one cache type must be unique.
400 InvalidIsp Invalid isp.Expected:UN,CM,CT,CTT,PBS,CE,Other, but receive:{} The error message returned because the ISP is invalid.
400 InvalidProvince Invalid province.Expected:beijing, neimenggu, shanxi and so on, but receive:{} The error message returned because the province is invalid.
400 InvalidEnable.ValueNotSupported The specified value of parameter Enable is not supported. The error message returned because the value of the Enable parameter is invalid.
400 ServerCertificate.MissingParameter An input parameter ServerCertificate that is mandatory for processing the request is not supplied. The error message returned because the ServerCertificate parameter is required.
400 PrivateKey.MissingParameter An input parameter PrivateKey that is mandatory for processing the request is not supplied. The error message returned because the PrivateKey parameter is required.
400 InvalidServerCertificate The ServerCertificate you provided is malformed! The error message returned because the certificate is invalid.
400 InvalidPrivateKey The Private Key you provided is malformed! The error message returned because the private key is invalid.
400 ServerCertificate.MissMatch The Private Key does not math the specified ServerCertificate! The error message returned because the certificate does not match the private key.
400 InvalidServerCertificate.TooLong The ServerCertificate you provided is over the max length! The error message returned because the size of the certificate or private key exceeds the upper limit.
400 Certificate.CertNull The Certificate is not null. The error message returned because the certificate is empty.
400 Certificate.FormatError The Certificate format is error. The error message returned because the certificate format is invalid.
400 Certificate.KeyNull The private key is not null. The error message returned because the private key is empty.
400 Key.Malformed The private key format is error. The error message returned because the private key format is invalid.
On this page
Pure ModeNormal Mode

Pure Mode

Click to preview the document content in full screen
Feedback