Skip to main content

Config the origin configuration of a Domain

Create or modify the origin configuration of a streaming domain name, which affects the HTTP-FLV streams of the domain

Request

Request-Line

POST /lls/v1.0/domain/{domain}/origin

Request Parameters

Path Parameters

ParameterTypeRequiredDescription
domainStringMandatorydomain name.

Request Body

ParameterTypeRequiredDescription
sourceTypeStringMandatoryOrigin pull method. Valid values are domain, ip.
domain: Origin pull from the customer's origin server. The origin server address is in the domain name format. Multiple domain names for origin pull can be configured. If origin pull fails, domain names are polled based on the configured sequence until origin pull succeeds.
ip: Origin pull from the customer's origin server. The origin server address is in the IP address format. Multiple IP addresses for origin pull can be configured. If origin pull fails, IP addresses are polled based on the configured sequence until origin pull succeeds. A maximum of one domain name for origin pull can be configured. During origin pull, set the header of httpflv HOST and the RTMP tcurl field to the configured domain name, respectively. Otherwise, the current IP address is used as the HOST.
originSchemaStringOptionalSchema for origin pull. Valid values are http, https. Default is https.
sourceDomainsArrayOptionalDomain names for origin pull. It is mandatory when the value of sourceType is "domain".
sourceIPsArrayOptionalIP addresses for origin pull. It is mandatory when the value of sourceType is "ip".
sourcePortIntegerOptionalPort for origin pull. It is mandatory when the value of sourceType is "ip".
sourceIPHostStringOptionalThe host of the IP address for origin pull. It is mandatory when the value of sourceType is "ip".

Response

Response Body

Status Codes, Error Codes and Error Messages

Status CodeError CodeError Message
400LLS.Domain.NotFoundDomain name is not found.

Examples

Modify the origin configuration of a Domain with domain names

Request

POST /lls/v1.0/domain/ingest.example.com/origin HTTP/1.1
{
"sourceType": "domain",
"originSchema": "https",
"sourceDomains": [
"first.customer1.com",
"second.customer2.com",
"third.customer3.com"
]
}

Modify the origin configuration of a Domain with IP addresses

Request

PUT /lls/v1.0/domain/ingest2.example.com/origin HTTP/1.1
{
"sourceType": "ip",
"originSchema": "http",
"sourceIPs": [
"38.0.101.76",
"51.15.16.17",
"62.60.226.226"
],
"sourcePort": 443,
"sourceIPHost": "origin2.example.com"
}

Best Practices

Rate Limiting

Rate Limits

Rate limiting is posed upon the API, please kindly check your API calls to ensure complying with the rate limit below:

  • 100 requests per minute
  • 1000 requests per hour