All Documents
Current Document

Content is empty

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

Documentation

GetCdnDomains

Last updated:2021-03-17 10:53:22

GetCdnDomains

Description

You can call this operation to query all domain names of the current account. The domain name information includes the domain name, ID, status, business type, business subtype, and CNAME domain name.

  • You can filter domain names in fuzzy match mode or by domain name status.
  • You can filter domain names by business type.

Request syntax

The API request contains the specified directory /2016-09-01/domain/GetCdnDomains, common request headers, and operation-specific request parameters. For more information, see the sample request.

Request parameters

Parameter Required Type Description
PageSize No Long The number of entries to return on each page. Default value: 20. Valid values: 1 to 500.
PageNumber No Long The number of the page to return. Default value: 1. Valid values: 1 to 10000.
DomainName No String The domain name, which can be up to 255 characters in length and is empty by default. If this parameter is left empty, all domain names of the current account are queried.
ProjectId No String The project ID. If this parameter is left empty, domain names in all projects are queried.
DomainStatus No String The status of the domain name, which is empty by default. If this parameter is left empty, domain names in all states are queried. For more information about the enumeration types, see Usage notes.
CdnType No String The business type, which is empty by default. Valid values: file, video, page, and live. Separate multiple business types with commas (,). If this parameter is left empty, domain names in all business types are queried.
FuzzyMatch No String Specifies whether to filter domain names in fuzzy match mode. Valid values: on and off. Default value: on.

Response parameters

Parameter Type Description
PageNumber Long The page number of the returned page.
PageSize Long The number of entries returned per page.
TotalCount Long The total number of domain names.
Domains Domain[] The domain names.

Domain

Parameter Type Description
DomainName String The domain name.
DomainId String The ID of the domain name.
Cname String The CNAME domain name that corresponds to the domain name.
CdnType String The business type. Valid values: file, video, page, and live.
CdnSubType String The business subtype. The response contains this parameter only when it is specified when you add the domain name. For more information about the enumeration types, see Usage notes.
IcpRegistration String The ICP filing number.
DomainStatus String The status of the domain name. For more information about the enumeration types, see Usage notes.
CreatedTime String The time when the domain name was created.
ModifiedTime String The time when the domain name was last modified.
Description String The review failure cause.

Enumeration types

DomainStatus

Domain name states include:

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

CdnSubType

Business subtypes include:

  • file
  • video
  • live
  • page

Examples

Sample request

GET method:

GET /2016-09-01/domain/GetCdnDomains?PageSize=20&PageNumber=1&DomainName=&DomainStatus=online&CdnType&FuzzyMatch=on 1.1
Host: cdn.api.ksyun.com
X-Amz-Date: date
Authorization:authorization string
x-action: GetCdnDomains
x-version: 2016-09-01

POST method:

POST /2016-09-01/domain/GetCdnDomains 1.1
Host: cdn.api.ksyun.com
X-Amz-Date: date
Authorization:authorization string
x-action: GetCdnDomains
x-version: 2016-09-01
Content-Type: application/x-www-form-urlencoded

PageSize=20&PageNumber=1&DomainName=&DomainStatus=online&CdnType&FuzzyMatch=on

Sample response

{
  "PageNumber": 1,
  "PageSize": 20,
  "TotalCount": 4,
  "Domains": [
    {
      "Description": "",
      "ModifiedTime": "2016-09-21T15:37+0800",
      "CreatedTime": "2016-09-21T15:37+0800",
      "IcpRegistration": "Hubei ICP Certificate No. 15011961-1",
      "DomainId": "2D09RCM",
      "CdnType": "live",
      "Cname": "www.test.com.hdlvcloud.ks-cdn.com",
      "CdnSubType": "video",
      "DomainName": "www.test.com",
      "DomainStatus": "online"
    },
    {
      "Description": "",
      "ModifiedTime": "2016-09-19T19:34+0800",
      "CreatedTime": "2016-09-19T19:34+0800",
      "IcpRegistration": "Beijing ICP Certificate No. 030173-1",
      "DomainId": "2D09RDG",
      "CdnType": "live",
      "Cname": "test2.com.hlsvcloud.ks-cdn.com",
      "CdnSubType": "video",
      "DomainName": "test2.com", 
     "DomainStatus": "online"
    },
    {
      "Description": "",
      "ModifiedTime": "2016-09-19T19:34+0800",
      "CreatedTime": "2016-09-19T19:34+0800",
      "IcpRegistration": "Beijing ICP Certificate No. 030173-1",
      "DomainId": "2D09RDG",
      "CdnType": "live",
      "Cname": "test3.com.hlsvcloud.ks-cdn.com",  
      "CdnSubType": "video",
      "DomainName": "test3.com", 
     "DomainStatus": "online"
    },
    {
      "Description": "",
      "ModifiedTime": "2016-09-19T17:49+0800",
      "CreatedTime": "2016-09-19T17:49+0800",
      "IcpRegistration": "Guangdong B2-20090191-2",
      "DomainId": "2D09RDK",
      "CdnType": "live",
      "Cname": "www.test4.com.hlsvcloud.ks-cdn.com",
      "CdnSubType": "video",
      "DomainName": "www.test4.com", 
     "DomainStatus": "online"
    }
  ]
}
On this page
Pure ModeNormal Mode

Pure Mode

Click to preview the document content in full screen
Feedback