Delivery Service¶
/api/1.2/deliveryservices¶
GET /api/1.2/deliveryservices
Retrieves all delivery services (if admin or ops) or all delivery services assigned to user. See also Using Traffic Ops - Delivery Service.
Authentication Required: Yes
Role(s) Required: None
Request Query Parameters
Name Required Description cdnno Filter delivery services by CDN ID. profileno Filter delivery services by Profile ID. tenantno Filter delivery services by Tenant ID. typeno Filter delivery services by Type ID. logsEnabledno Filter by logs enabled (true|false). Response Properties
Parameter Type Description activebool true if active, false if inactive. anonymousBlockingEnabledbool
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurlstring Cache URL rule to apply to this delivery service. ccrDnsTtlint The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr. host. cdnIdint Id of the CDN to which the delivery service belongs to. cdnNamestring Name of the CDN to which the delivery service belongs to. checkPathstring The path portion of the URL to check this deliveryservice for health. deepCachingTypestring When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayNamestring The display name of the delivery service. dnsBypassCnamestring dnsBypassIpstring The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6string The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtlint The TTL of the DNS bypass response. dscpint The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewritestring The EDGE header rewrite actions to perform. exampleURLsarray Entry points into the CDN for this deliveryservice. geoLimitRedirectUrlstring geoLimitint
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from USA
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountriesstring geoProviderint globalMaxMbpsint The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTpsint The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices fqPacingRateint The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature httpBypassFqdnstring The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. idint The deliveryservice id (database row number). infoUrlstring Use this to add a URL that points to more information about that deliveryservice. initialDispersionint ipv6RoutingEnabledbool false: send IPv4 address of Traffic Router to client on HTTP type del. lastUpdatedstring logsEnabledbool longDescstring Description field. longDesc1string Description field 1. longDesc2string Description field 2. maxDnsAnswersint The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewritestring The MID header rewrite actions to perform. missLatfloat The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. 39.7391500 or null missLongfloat The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. -104.9847000 or null multiSiteOriginbool Is the Multi Site Origin feature enabled for this delivery service (0=false, 1=true). See Multi Site Origin orgServerFqdnstring The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. originShieldstring profileDescriptionstring The description of the Traffic Router Profile with which this deliveryservice is associated. profileIdint The id of the Traffic Router Profile with which this deliveryservice is associated. profileNamestring The name of the Traffic Router Profile with which this deliveryservice is associated. protocolint qstringIgnoreint
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
rangeRequestHandlingint How to treat range requests: - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemapstring Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlockingbool Regex Remap rule to apply to this delivery service at the Edge tier. remapTextstring Additional raw remap line text. routingNamestring The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signedbool
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithmstring
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersionint tenantstring Owning tenant name tenantIdint Owning tenant ID trRequestHeadersstring List of header keys separated by __RETURN__. Listed headers will be included in TR access log entries under the “rh=” token. trResponseHeadersstring List of header name:value pairs separated by __RETURN__. Listed pairs will be included in all TR HTTP responses. typeIdint The type of this deliveryservice (one of :ref:to-api-v11-types use_in_table=’deliveryservice’). xmlIdstring Unique string that describes this deliveryservice. Response Example
{ "response": [ { "active": true, "anonymousBlockingEnabled": false, "cacheurl": null, "ccrDnsTtl": "3600", "cdnId": "2", "cdnName": "over-the-top", "checkPath": "", "deepCachingType": "NEVER", "displayName": "My Cool Delivery Service", "dnsBypassCname": "", "dnsBypassIp": "", "dnsBypassIp6": "", "dnsBypassTtl": "30", "dscp": "40", "edgeHeaderRewrite": null, "exampleURLs": [ "http://foo.foo-ds.foo.bar.net" ], "geoLimit": "0", "geoLimitCountries": null, "geoLimitRedirectURL": null, "geoProvider": "0", "globalMaxMbps": null, "globalMaxTps": "0", "fqPacingRate": "0", "httpBypassFqdn": "", "id": "442", "infoUrl": "", "initialDispersion": "1", "ipv6RoutingEnabled": true, "lastUpdated": "2016-01-26 08:49:35", "logsEnabled": false, "longDesc": "", "longDesc1": "", "longDesc2": "", "maxDnsAnswers": "0", "midHeaderRewrite": null, "missLat": "39.7391500", "missLong": "-104.9847000", "multiSiteOrigin": false, "orgServerFqdn": "http://baz.boo.net", "originShield": null, "profileDescription": "Content Router for over-the-top", "profileId": "5", "profileName": "ROUTER_TOP", "protocol": "0", "qstringIgnore": "1", "rangeRequestHandling": "0", "regexRemap": null, "regionalGeoBlocking": false, "remapText": null, "routingName": "foo", "signed": false, "signingAlgorithm": null, "sslKeyVersion": "0", "tenant": "root", "tenantId": 1, "trRequestHeaders": null, "trResponseHeaders": "Access-Control-Allow-Origin: *", "type": "HTTP", "typeId": "8", "xmlId": "foo-ds" } { .. }, { .. } ] }
GET /api/1.2/deliveryservices/:id
Retrieves a specific delivery service. If not admin / ops, delivery service must be assigned to user. See also Using Traffic Ops - Delivery Service.
Authentication Required: Yes
Role(s) Required: None
Request Route Parameters
Name Required Description idyes Delivery service ID. Response Properties
Parameter Type Description activebool true if active, false if inactive. anonymousBlockingEnabledbool
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurlstring Cache URL rule to apply to this delivery service. ccrDnsTtlint The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr. host. cdnIdint Id of the CDN to which the delivery service belongs to. cdnNamestring Name of the CDN to which the delivery service belongs to. checkPathstring The path portion of the URL to check this deliveryservice for health. deepCachingTypestring When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayNamestring The display name of the delivery service. dnsBypassCnamestring dnsBypassIpstring The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6string The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtlint The TTL of the DNS bypass response. dscpint The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewritestring The EDGE header rewrite actions to perform. exampleURLsarray Entry points into the CDN for this deliveryservice. fqPacingRateint The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectUrlstring geoLimitint
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from USA
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountriesstring geoProviderint globalMaxMbpsint The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTpsint The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdnstring The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. idint The deliveryservice id (database row number). infoUrlstring Use this to add a URL that points to more information about that deliveryservice. initialDispersionint ipv6RoutingEnabledbool false: send IPv4 address of Traffic Router to client on HTTP type del. lastUpdatedstring logsEnabledbool longDescstring Description field. longDesc1string Description field 1. longDesc2string Description field 2. matchListarray Array of matchList hashes. >>typestring The type of MatchList (one of :ref:to-api-v11-types use_in_table=’regex’). >>setNumberstring The set Number of the matchList. >>patternstring The regexp for the matchList. maxDnsAnswersint The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewritestring The MID header rewrite actions to perform. missLatfloat The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. 39.7391500 or null missLongfloat The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. -104.9847000 or null multiSiteOriginbool Is the Multi Site Origin feature enabled for this delivery service (0=false, 1=true). See Multi Site Origin orgServerFqdnstring The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. originShieldstring profileDescriptionstring The description of the Traffic Router Profile with which this deliveryservice is associated. profileIdint The id of the Traffic Router Profile with which this deliveryservice is associated. profileNamestring The name of the Traffic Router Profile with which this deliveryservice is associated. protocolint qstringIgnoreint
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
rangeRequestHandlingint How to treat range requests: - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemapstring Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlockingbool Regex Remap rule to apply to this delivery service at the Edge tier. remapTextstring Additional raw remap line text. routingNamestring The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signedbool
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithmstring
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersionint tenantstring Owning tenant name tenantIdint Owning tenant ID trRequestHeadersstring trResponseHeadersstring typeIdint The type of this deliveryservice (one of :ref:to-api-v11-types use_in_table=’deliveryservice’). xmlIdstring Unique string that describes this deliveryservice. Response Example
{ "response": [ { "active": true, "anonymousBlockingEnabled": false, "cacheurl": null, "ccrDnsTtl": "3600", "cdnId": "2", "cdnName": "over-the-top", "checkPath": "", "deepCachingType": "NEVER", "displayName": "My Cool Delivery Service", "dnsBypassCname": "", "dnsBypassIp": "", "dnsBypassIp6": "", "dnsBypassTtl": "30", "dscp": "40", "edgeHeaderRewrite": null, "exampleURLs": [ "http://foo.foo-ds.foo.bar.net" ], "geoLimit": "0", "geoLimitCountries": null, "geoLimitRedirectURL": null, "geoProvider": "0", "globalMaxMbps": null, "globalMaxTps": "0", "fqPacingRate": "0", "httpBypassFqdn": "", "id": "442", "infoUrl": "", "initialDispersion": "1", "ipv6RoutingEnabled": true, "lastUpdated": "2016-01-26 08:49:35", "logsEnabled": false, "longDesc": "", "longDesc1": "", "longDesc2": "", "matchList": [ { "pattern": ".*\\.foo-ds\\..*", "setNumber": "0", "type": "HOST_REGEXP" } ], "maxDnsAnswers": "0", "midHeaderRewrite": null, "missLat": "39.7391500", "missLong": "-104.9847000", "multiSiteOrigin": false, "orgServerFqdn": "http://baz.boo.net", "originShield": null, "profileDescription": "Content Router for over-the-top", "profileId": "5", "profileName": "ROUTER_TOP", "protocol": "0", "qstringIgnore": "1", "rangeRequestHandling": "0", "regexRemap": null, "regionalGeoBlocking": false, "remapText": null, "routingName": "foo", "signed": false, "signingAlgorithm": null, "sslKeyVersion": "0", "tenant": "root", "tenantId": 1, "trRequestHeaders": null, "trResponseHeaders": "Access-Control-Allow-Origin: *", "type": "HTTP", "typeId": "8", "xmlId": "foo-ds" } ] }
GET /api/1.2/deliveryservices/:id/servers
Retrieves properties of CDN EDGE or ORG servers assigned to a delivery service.
Authentication Required: Yes
Role(s) Required: Admin or Operations or delivery service must be assigned to user.
Request Route Parameters
Name Required Description idyes Delivery service ID. Response Properties
Parameter Type Description cachegroupstring The cache group name (see Cache Group). cachegroupIdstring The cache group id. cdnIdstring Id of the CDN to which the server belongs to. cdnNamestring Name of the CDN to which the server belongs to. domainNamestring The domain name part of the FQDN of the cache. guidstring An identifier used to uniquely identify the server. hostNamestring The host name part of the cache. httpsPortstring The HTTPS port on which the main application listens (443 in most cases). idstring The server id (database row number). iloIpAddressstring The IPv4 address of the lights-out-management port. iloIpGatewaystring The IPv4 gateway address of the lights-out-management port. iloIpNetmaskstring The IPv4 netmask of the lights-out-management port. iloPasswordstring The password of the of the lights-out-management user (displays as ** unless you are an ‘admin’ user). iloUsernamestring The user name for lights-out-management. interfaceMtustring The Maximum Transmission Unit (MTU) to configure for interfaceName.interfaceNamestring The network interface name used for serving traffic. ip6Addressstring The IPv6 address/netmask for interfaceName.ip6Gatewaystring The IPv6 gateway for interfaceName.ipAddressstring The IPv4 address for interfaceName.ipGatewaystring The IPv4 gateway for interfaceName.ipNetmaskstring The IPv4 netmask for interfaceName.lastUpdatedstring The Time and Date for the last update for this server. mgmtIpAddressstring The IPv4 address of the management port (optional). mgmtIpGatewaystring The IPv4 gateway of the management port (optional). mgmtIpNetmaskstring The IPv4 netmask of the management port (optional). offlineReasonstring A user-entered reason why the server is in ADMIN_DOWN or OFFLINE status. physLocationstring The physical location name (see Physical Location). physLocationIdstring The physical location id (see Physical Location). profilestring The assigned profile name (see Profiles). profileDescstring The assigned profile description (see Profiles). profileIdstring The assigned profile Id (see Profiles). rackstring A string indicating rack location. routerHostNamestring The human readable name of the router. routerPortNamestring The human readable name of the router port. statusstring The Status string (See Status). statusIdstring The Status id (See Status). tcpPortstring The default TCP port on which the main application listens (80 for a cache in most cases). typestring The name of the type of this server (see Types). typeIdstring The id of the type of this server (see Types). updPendingbool Response Example
{ "response": [ { "cachegroup": "us-il-chicago", "cachegroupId": "3", "cdnId": "3", "cdnName": "CDN-1", "domainName": "chi.kabletown.net", "guid": null, "hostName": "atsec-chi-00", "id": "19", "iloIpAddress": "172.16.2.6", "iloIpGateway": "172.16.2.1", "iloIpNetmask": "255.255.255.0", "iloPassword": "********", "iloUsername": "", "interfaceMtu": "9000", "interfaceName": "bond0", "ip6Address": "2033:D0D0:3300::2:2/64", "ip6Gateway": "2033:D0D0:3300::2:1", "ipAddress": "10.10.2.2", "ipGateway": "10.10.2.1", "ipNetmask": "255.255.255.0", "lastUpdated": "2015-03-08 15:57:32", "mgmtIpAddress": "", "mgmtIpGateway": "", "mgmtIpNetmask": "", "offlineReason": "N/A", "physLocation": "plocation-chi-1", "physLocationId": "9", "profile": "EDGE1_CDN1_421_SSL", "profileDesc": "EDGE1_CDN1_421_SSL profile", "profileId": "12", "rack": "RR 119.02", "routerHostName": "rtr-chi.kabletown.net", "routerPortName": "2", "status": "ONLINE", "statusId": "6", "tcpPort": "80", "httpsPort": "443", "type": "EDGE", "typeId": "3", "updPending": false }, { ... more server data } ] }
GET /api/1.2/deliveryservices/:id/servers/unassigned
Retrieves properties of CDN EDGE or ORG servers not assigned to a delivery service.
Authentication Required: Yes
Role(s) Required: Admin or Operations or delivery service must be assigned to user
Request Route Parameters
Name Required Description idyes Delivery service ID. Response Properties
Parameter Type Description cachegroupstring The cache group name (see Cache Group). cachegroupIdstring The cache group id. cdnIdstring Id of the CDN to which the server belongs to. cdnNamestring Name of the CDN to which the server belongs to. domainNamestring The domain name part of the FQDN of the cache. guidstring An identifier used to uniquely identify the server. hostNamestring The host name part of the cache. httpsPortstring The HTTPS port on which the main application listens (443 in most cases). idstring The server id (database row number). iloIpAddressstring The IPv4 address of the lights-out-management port. iloIpGatewaystring The IPv4 gateway address of the lights-out-management port. iloIpNetmaskstring The IPv4 netmask of the lights-out-management port. iloPasswordstring The password of the of the lights-out-management user (displays as ** unless you are an ‘admin’ user). iloUsernamestring The user name for lights-out-management. interfaceMtustring The Maximum Transmission Unit (MTU) to configure for interfaceName.interfaceNamestring The network interface name used for serving traffic. ip6Addressstring The IPv6 address/netmask for interfaceName.ip6Gatewaystring The IPv6 gateway for interfaceName.ipAddressstring The IPv4 address for interfaceName.ipGatewaystring The IPv4 gateway for interfaceName.ipNetmaskstring The IPv4 netmask for interfaceName.lastUpdatedstring The Time and Date for the last update for this server. mgmtIpAddressstring The IPv4 address of the management port (optional). mgmtIpGatewaystring The IPv4 gateway of the management port (optional). mgmtIpNetmaskstring The IPv4 netmask of the management port (optional). offlineReasonstring A user-entered reason why the server is in ADMIN_DOWN or OFFLINE status. physLocationstring The physical location name (see Physical Location). physLocationIdstring The physical location id (see Physical Location). profilestring The assigned profile name (see Profiles). profileDescstring The assigned profile description (see Profiles). profileIdstring The assigned profile Id (see Profiles). rackstring A string indicating rack location. routerHostNamestring The human readable name of the router. routerPortNamestring The human readable name of the router port. statusstring The Status string (See Status). statusIdstring The Status id (See Status). tcpPortstring The default TCP port on which the main application listens (80 for a cache in most cases). typestring The name of the type of this server (see Types). typeIdstring The id of the type of this server (see Types). updPendingbool Response Example
{ "response": [ { "cachegroup": "us-il-chicago", "cachegroupId": "3", "cdnId": "3", "cdnName": "CDN-1", "domainName": "chi.kabletown.net", "guid": null, "hostName": "atsec-chi-00", "id": "19", "iloIpAddress": "172.16.2.6", "iloIpGateway": "172.16.2.1", "iloIpNetmask": "255.255.255.0", "iloPassword": "********", "iloUsername": "", "interfaceMtu": "9000", "interfaceName": "bond0", "ip6Address": "2033:D0D0:3300::2:2/64", "ip6Gateway": "2033:D0D0:3300::2:1", "ipAddress": "10.10.2.2", "ipGateway": "10.10.2.1", "ipNetmask": "255.255.255.0", "lastUpdated": "2015-03-08 15:57:32", "mgmtIpAddress": "", "mgmtIpGateway": "", "mgmtIpNetmask": "", "offlineReason": "N/A", "physLocation": "plocation-chi-1", "physLocationId": "9", "profile": "EDGE1_CDN1_421_SSL", "profileDesc": "EDGE1_CDN1_421_SSL profile", "profileId": "12", "rack": "RR 119.02", "routerHostName": "rtr-chi.kabletown.net", "routerPortName": "2", "status": "ONLINE", "statusId": "6", "tcpPort": "80", "httpsPort": "443", "type": "EDGE", "typeId": "3", "updPending": false }, { ... more server data } ] }
GET /api/1.2/deliveryservices/:id/servers/eligible
Retrieves properties of CDN EDGE or ORG servers not eligible for assignment to a delivery service.
Authentication Required: Yes
Role(s) Required: Admin or Operations or delivery service must be assigned to user
Request Route Parameters
Name Required Description idyes Delivery service ID. Response Properties
Parameter Type Description cachegroupstring The cache group name (see Cache Group). cachegroupIdstring The cache group id. cdnIdstring Id of the CDN to which the server belongs to. cdnNamestring Name of the CDN to which the server belongs to. domainNamestring The domain name part of the FQDN of the cache. guidstring An identifier used to uniquely identify the server. hostNamestring The host name part of the cache. httpsPortstring The HTTPS port on which the main application listens (443 in most cases). idstring The server id (database row number). iloIpAddressstring The IPv4 address of the lights-out-management port. iloIpGatewaystring The IPv4 gateway address of the lights-out-management port. iloIpNetmaskstring The IPv4 netmask of the lights-out-management port. iloPasswordstring The password of the of the lights-out-management user (displays as ** unless you are an ‘admin’ user). iloUsernamestring The user name for lights-out-management. interfaceMtustring The Maximum Transmission Unit (MTU) to configure for interfaceName.interfaceNamestring The network interface name used for serving traffic. ip6Addressstring The IPv6 address/netmask for interfaceName.ip6Gatewaystring The IPv6 gateway for interfaceName.ipAddressstring The IPv4 address for interfaceName.ipGatewaystring The IPv4 gateway for interfaceName.ipNetmaskstring The IPv4 netmask for interfaceName.lastUpdatedstring The Time and Date for the last update for this server. mgmtIpAddressstring The IPv4 address of the management port (optional). mgmtIpGatewaystring The IPv4 gateway of the management port (optional). mgmtIpNetmaskstring The IPv4 netmask of the management port (optional). offlineReasonstring A user-entered reason why the server is in ADMIN_DOWN or OFFLINE status. physLocationstring The physical location name (see Physical Location). physLocationIdstring The physical location id (see Physical Location). profilestring The assigned profile name (see Profiles). profileDescstring The assigned profile description (see Profiles). profileIdstring The assigned profile Id (see Profiles). rackstring A string indicating rack location. routerHostNamestring The human readable name of the router. routerPortNamestring The human readable name of the router port. statusstring The Status string (See Status). statusIdstring The Status id (See Status). tcpPortstring The default TCP port on which the main application listens (80 for a cache in most cases). typestring The name of the type of this server (see Types). typeIdstring The id of the type of this server (see Types). updPendingbool Response Example
{ "response": [ { "cachegroup": "us-il-chicago", "cachegroupId": "3", "cdnId": "3", "cdnName": "CDN-1", "domainName": "chi.kabletown.net", "guid": null, "hostName": "atsec-chi-00", "id": "19", "iloIpAddress": "172.16.2.6", "iloIpGateway": "172.16.2.1", "iloIpNetmask": "255.255.255.0", "iloPassword": "********", "iloUsername": "", "interfaceMtu": "9000", "interfaceName": "bond0", "ip6Address": "2033:D0D0:3300::2:2/64", "ip6Gateway": "2033:D0D0:3300::2:1", "ipAddress": "10.10.2.2", "ipGateway": "10.10.2.1", "ipNetmask": "255.255.255.0", "lastUpdated": "2015-03-08 15:57:32", "mgmtIpAddress": "", "mgmtIpGateway": "", "mgmtIpNetmask": "", "offlineReason": "N/A", "physLocation": "plocation-chi-1", "physLocationId": "9", "profile": "EDGE1_CDN1_421_SSL", "profileDesc": "EDGE1_CDN1_421_SSL profile", "profileId": "12", "rack": "RR 119.02", "routerHostName": "rtr-chi.kabletown.net", "routerPortName": "2", "status": "ONLINE", "statusId": "6", "tcpPort": "80", "httpsPort": "443", "type": "EDGE", "typeId": "3", "updPending": false }, { ... more server data } ] }
Health¶
GET /api/1.2/deliveryservices/:id/state
Retrieves the failover state for a delivery service. Delivery service must be assigned to user if user is not admin or operations.
Authentication Required: Yes
Role(s) Required: None
Response Properties
Parameter Type Description failoverhash >locationsarray >destinationhash >>locationstring >>typestring >configuredboolean >enabledboolean enabledboolean Response Example
{ "response": { "failover": { "locations": [ ], "destination": { "location": null, "type": "DNS", }, "configured": false, "enabled": false }, "enabled": true } }
GET /api/1.2/deliveryservices/:id/health
Retrieves the health of all locations (cache groups) for a delivery service. Delivery service must be assigned to user if user is not admin or operations.
Authentication Required: Yes
Role(s) Required: None
Response Properties
Parameter Type Description totalOnlineint Total number of online caches across all CDNs. totalOfflineint Total number of offline caches across all CDNs. cachegroupsarray A collection of cache groups. >onlineint The number of online caches for the cache group >offlineint The number of offline caches for the cache group. >namestring Cache group name. Response Example
{ "response": { "totalOnline": 148, "totalOffline": 0, "cachegroups": [ { "online": 8, "offline": 0, "name": "us-co-denver" }, { "online": 7, "offline": 0, "name": "us-de-newcastle" } ] } }
GET /api/1.2/deliveryservices/:id/capacity
Retrieves the capacity percentages of a delivery service. Delivery service must be assigned to user if user is not admin or operations.
Authentication Required: Yes
Role(s) Required: None
Request Route Parameters
Name Required Description id yes delivery service id. Response Properties
Parameter Type Description availablePercentnumber The percentage of server capacity assigned to the delivery service that is available. unavailablePercentnumber The percentage of server capacity assigned to the delivery service that is unavailable. utilizedPercentnumber The percentage of server capacity assigned to the delivery service being used. maintenancePercentnumber The percentage of server capacity assigned to the delivery service that is down for maintenance. Response Example
{ "response": { "availablePercent": 89.0939840205533, "unavailablePercent": 0, "utilizedPercent": 10.9060020300395, "maintenancePercent": 0.0000139494071146245 }, }
GET /api/1.2/deliveryservices/:id/routing
Retrieves the routing method percentages of a delivery service. Delivery service must be assigned to user if user is not admin or operations.
Authentication Required: Yes
Role(s) Required: None
Request Route Parameters
Name Required Description id yes delivery service id. Response Properties
Parameter Type Description staticRoutenumber The percentage of Traffic Router responses for this deliveryservice satisfied with pre-configured DNS entries. missnumber The percentage of Traffic Router responses for this deliveryservice that were a miss (no location available for client IP). geonumber The percentage of Traffic Router responses for this deliveryservice satisfied using 3rd party geo-IP mapping. errnumber The percentage of Traffic Router requests for this deliveryservice resulting in an error. cznumber The percentage of Traffic Router requests for this deliveryservice satisfied by a CZF (coverage zone file) hit. dsrnumber The percentage of Traffic Router requests for this deliveryservice satisfied by sending the client to the overflow CDN. fednumber The percentage of Traffic Router requests for this deliveryservice satisfied by sending the client to a federated CDN. regionalAlternatenumber The percentage of Traffic Router requests for this deliveryservice satisfied by sending the client to the alternate regional geoblocking URL. regionalDeniednumber The percent of Traffic Router requests for this deliveryservice denied due to geolocation policy. Response Example
{ "response": { "staticRoute": 0, "miss": 0, "geo": 37.8855391018869, "err": 0, "cz": 62.1144608981131, "dsr": 0, "fed": 0, "regionalAlternate": 0, "regionalDenied": 0 }, }
Delivery Service Server¶
GET /api/1.2/deliveryserviceserver
Retrieves delivery service / server assignments.
Authentication Required: Yes
Role(s) Required: None
Request Query Parameters
Name Required Description pageno The page number for use in pagination. limitno For use in limiting the result set. Response Properties
Parameter Type Description lastUpdatedarray serverstring deliveryServicestring Response Example
{ "page": 2, "orderby": "deliveryservice", "response": [ { "lastUpdated": "2014-09-26 17:53:43", "server": "20", "deliveryService": "1" }, { "lastUpdated": "2014-09-26 17:53:44", "server": "21", "deliveryService": "1" }, ], "limit": 2 }
POST /api/1.2/deliveryserviceserver
Create one or more delivery service / server assignments.
Authentication Required: Yes
Role(s) Required: Admin or Operations or the delivery service is assigned to the user.
Request Parameters
Name Required Description dsIdyes The ID of the delivery service. serversyes An array of server IDs. replaceno Replace existing ds/server assignments? (true|false) Request Example
{ "dsId": 246, "servers": [ 2, 3, 4, 5, 6 ], "replace": true }Response Properties
Parameter Type Description dsIdint The ID of the delivery service. serversarray An array of server IDs. replacearray Existing ds/server assignments replaced? (true|false). Response Example
{ "alerts": [ { "level": "success", "text": "Server assignments complete." } ], "response": { "dsId" : 246, "servers" : [ 2, 3, 4, 5, 6 ], "replace" : true } }
DELETE /api/1.2/deliveryservice_server/:dsId/:serverId
Removes a server (cache) from a delivery service.
Authentication Required: Yes
Role(s) Required: Admin or Oper (if delivery service is not assigned to user)
Request Route Parameters
Name Required Description dsIdyes Delivery service ID. serverIdyes Server (cache) ID. Response Example
{ "alerts": [ { "level": "success", "text": "Server unlinked from delivery service." } ], }
Delivery Service User¶
POST /api/1.2/deliveryservice_user
Create one or more user / delivery service assignments.
Authentication Required: Yes
Role(s) Required: Admin or Operations
Request Parameters
Name Required Description userIdyes The ID of the user. deliveryServicesyes An array of delivery service IDs. replaceno Replace existing user/ds assignments? (true|false). Request Example
{ "userId": 50, "deliveryServices": [ 23, 34, 45, 56, 67 ], "replace": true }Response Properties
Parameter Type Description userIdint The ID of the user. deliveryServicesarray An array of delivery service IDs. replacearray Existing user/ds assignments replaced? (true|false). Response Example
{ "alerts": [ { "level": "success", "text": "Delivery service assignments complete." } ], "response": { "userId" : 50, "deliveryServices": [ 23, 34, 45, 56, 67 ], "replace": true } }
DELETE /api/1.2/deliveryservice_user/:dsId/:userId
Removes a delivery service from a user.
Authentication Required: Yes
Role(s) Required: Admin or Operations
Request Route Parameters
Name Required Description dsIdyes Delivery service ID. userIdyes User ID. Response Example
{ "alerts": [ { "level": "success", "text": "User and delivery service were unlinked." } ], }
SSL Keys¶
GET /api/1.2/deliveryservices/xmlId/:xmlid/sslkeys
Retrieves ssl keys for a delivery service.
Authentication Required: Yes
Role(s) Required: None
Request Route Parameters
Name Required Description xmlIdyes xml_id of the desired delivery service Request Query Parameters
Name Required Description versionno The version number to retrieve decodeno a boolean value to decode the certs or not Response Properties
Parameter Type Description crtstring base64 encoded (or not if decode=true) crt file for delivery service csrstring base64 encoded (or not if decode=true) csr file for delivery service keystring base64 encoded (or not if decode=true) private key file for delivery service cdnstring The CDN of the delivery service for which the certs were generated. deliveryservicestring The XML ID of the delivery service for which the cert was generated. businessUnitstring The business unit entered by the user when generating certs. Field is optional and if not provided by the user will not be in response citystring The city entered by the user when generating certs. Field is optional and if not provided by the user will not be in response organizationstring The organization entered by the user when generating certs. Field is optional and if not provided by the user will not be in response hostnamestring The hostname generated by Traffic Ops that is used as the common name when generating the certificate. This will be a FQDN for DNS delivery services and a wildcard URL for HTTP delivery services. countrystring The country entered by the user when generating certs. Field is optional and if not provided by the user will not be in response statestring The state entered by the user when generating certs. Field is optional and if not provided by the user will not be in response versionstring The version of the certificate record in Riak Response Example
{ "response": { "certificate": { "crt": "crt", "key": "key", "csr": "csr" }, "deliveryservice": "my-ds", "cdn": "qa", "businessUnit": "CDN_Eng", "city": "Denver", "organization": "KableTown", "hostname": "foober.com", "country": "US", "state": "Colorado", "version": "1" } }
GET /api/1.2/deliveryservices/hostname/:hostname/sslkeys
Authentication Required: Yes
Role(s) Required: Admin
Request Route Parameters
Name Required Description hostnameyes pristine hostname of the desired delivery service Request Query Parameters
Name Required Description versionno The version number to retrieve decodeno a boolean value to decode the certs or not Response Properties
Parameter Type Description crtstring base64 encoded (or not if decode=true) crt file for delivery service csrstring base64 encoded (or not if decode=true) csr file for delivery service keystring base64 encoded (or not if decode=true) private key file for delivery service cdnstring The CDN of the delivery service for which the certs were generated. deliveryservicestring The XML ID of the delivery service for which the cert was generated. businessUnitstring The business unit entered by the user when generating certs. Field is optional and if not provided by the user will not be in response citystring The city entered by the user when generating certs. Field is optional and if not provided by the user will not be in response organizationstring The organization entered by the user when generating certs. Field is optional and if not provided by the user will not be in response hostnamestring The hostname generated by Traffic Ops that is used as the common name when generating the certificate. This will be a FQDN for DNS delivery services and a wildcard URL for HTTP delivery services. countrystring The country entered by the user when generating certs. Field is optional and if not provided by the user will not be in response statestring The state entered by the user when generating certs. Field is optional and if not provided by the user will not be in response versionstring The version of the certificate record in Riak Response Example
{ "response": { "certificate": { "crt": "crt", "key": "key", "csr": "csr" }, "deliveryservice": "my-ds", "cdn": "qa", "businessUnit": "CDN_Eng", "city": "Denver", "organization": "KableTown", "hostname": "foober.com", "country": "US", "state": "Colorado", "version": "1" } }
GET /api/1.2/deliveryservices/xmlId/:xmlid/sslkeys/delete
Authentication Required: Yes
Role Required: Operations
Request Route Parameters
Name Required Description xmlIdyes xml_id of the desired delivery service Request Query Parameters
Name Required Description versionno The version number to retrieve Response Properties
Parameter Type Description responsestring success response Response Example
{ "response": "Successfully deleted ssl keys for <xml_id>" }
POST /api/1.2/deliveryservices/sslkeys/generate
Generates SSL crt, csr, and private key for a delivery service
Authentication Required: Yes
Role(s) Required: Operations
Request Properties
Parameter Type Description keystring xml_id of the delivery service versionstring version of the keys being generated hostnamestring the pristine hostname of the delivery service countrystring Country statestring State citystring City orgstring Organization unitboolean Business Unit deliveryservicestring The deliveryservice xml-id for which you want to generate certs cdnstring The name of the CDN for which the deliveryservice belongs Request Example
{ "key": "ds-01", "businessUnit": "CDN Engineering", "version": "3", "hostname": "tr.ds-01.ott.kabletown.com", "certificate": { "key": "some_key", "csr": "some_csr", "crt": "some_crt" }, "country": "US", "organization": "Kabletown", "city": "Denver", "state": "Colorado", "deliveryservice" : "ds-01", "cdn": "cdn1" }
Response Properties
Parameter Type Description responsestring response string versionstring API version Response Example
{ "response": "Successfully created ssl keys for ds-01" }
POST /api/1.2/deliveryservices/sslkeys/add
Allows user to add SSL crt, csr, and private key for a delivery service.
Authentication Required: Yes
Role(s) Required: Operations
Request Properties
Parameter Type Description keystring xml_id of the delivery service versionstring version of the keys being generated csrstring crtstring keystring deliveryservicestring The deliveryservice xml-id for which you want to generate certs cdnstring The name of the CDN for which the deliveryservice belongs hostnamestring the pristine hostname of the delivery service Request Example
{ "key": "ds-01", "version": "1", "certificate": { "key": "some_key", "csr": "some_csr", "crt": "some_crt" } }
Response Properties
Parameter Type Description responsestring response string versionstring API version Response Example
{ "response": "Successfully added ssl keys for ds-01" }
URL Sig Keys¶
GET /api/1.2/deliveryservices/xmlId/:xmlid/urlkeys
Retrieves URL sig keys for a delivery service.
Authentication Required: Yes
Role(s) Required: None
Request Route Parameters
Name Required Description xmlIdyes xml_id of the desired delivery service Response Properties
Parameter Type Description key0string base64 encoded key for delivery service key2string base64 encoded key for delivery service keyn...string base64 encoded key for delivery service – repeats to 15 (16 total) and is currently unsorted. Response Example
{ "response": { key9":"ZvVQNYpPVQWQV8tjQnUl6osm4y7xK4zD", "key6":"JhGdpw5X9o8TqHfgezCm0bqb9SQPASWL", "key8":"ySXdp1T8IeDEE1OCMftzZb9EIw_20wwq", "key0":"D4AYzJ1AE2nYisA9MxMtY03TPDCHji9C", "key3":"W90YHlGc_kYlYw5_I0LrkpV9JOzSIneI", "key12":"ZbtMb3mrKqfS8hnx9_xWBIP_OPWlUpzc", "key2":"0qgEoDO7sUsugIQemZbwmMt0tNCwB1sf", "key4":"aFJ2Gb7atmxVB8uv7T9S6OaDml3ycpGf", "key1":"wnWNR1mCz1O4C7EFPtcqHd0xUMQyNFhA", "key11":"k6HMzlBH1x6htKkypRFfWQhAndQqe50e", "key10":"zYONfdD7fGYKj4kLvIj4U0918csuZO0d", "key15":"3360cGaIip_layZMc_0hI2teJbazxTQh", "key5":"SIwv3GOhWN7EE9wSwPFj18qE4M07sFxN", "key13":"SqQKBR6LqEOzp8AewZUCVtBcW_8YFc1g", "key14":"DtXsu8nsw04YhT0kNoKBhu2G3P9WRpQJ", "key7":"cmKoIIxXGAxUMdCsWvnGLoIMGmNiuT5I" } }
POST /api/1.2/deliveryservices/xmlId/:xmlid/urlkeys/generate
Generates Url sig keys for a delivery service
Authentication Required: Yes
Role(s) Required: Operations
Request Route Parameters
Name Required Description xmlIdyes xml_id of the desired delivery service
Response Properties
Parameter Type Description responsestring response string versionstring API version Response Example
{ "response": "Successfully generated and stored keys" }
POST /api/1.2/deliveryservices/xmlId/:xmlid/urlkeys/copyFromXmlId/:copyFromXmlId
Allows user to copy url sig keys from a specified delivery service to a delivery service.
Authentication Required: Yes
Role(s) Required: Operations
Request Route Parameters
Name Required Description xmlIdyes xml_id of the desired delivery service copyFromXmlIdyes xml_id of the delivery service to copy url sig keys from
Response Properties
Parameter Type Description responsestring response string versionstring API version Response Example
{ "response": "Successfully copied and stored keys" }
POST /api/1.2/deliveryservices/request
Allows a user to send delivery service request details to a specified email address.
Authentication Required: Yes
Role(s) Required: None
Request Properties
Parameter Type Required Description emailTostring yes The email to which the delivery service request will be sent. detailshash yes Parameters for the delivery service request. >customerstring yes Name of the customer to associated with the delivery service. >deepCachingTypestring no When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
>deliveryProtocolstring yes Eg. http or http/https >routingTypestring yes Eg. DNS or HTTP Redirect >routingNamestring no The routing name for the delivery service, e.g. <routingName>.<xmlId>.cdn.com >serviceDescstring yes A description of the delivery service. >peakBPSEstimatestring yes Used to manage cache efficiency and plan for capacity. >peakTPSEstimatestring yes Used to manage cache efficiency and plan for capacity. >maxLibrarySizeEstimatestring yes Used to manage cache efficiency and plan for capacity. >originURLstring yes The URL path to the origin server. >hasOriginDynamicRemapbool yes This is a feature which allows services to use multiple origin URLs for the same service. >originTestFilestring yes A URL path to a test file available on the origin server. >hasOriginACLWhitelistbool yes Is access to your origin restricted using an access control list (ACL or whitelist) of Ips? >originHeadersstring no Header values that must be passed to requests to your origin. >otherOriginSecuritystring no Other origin security measures that need to be considered for access. >queryStringHandlingstring yes How to handle query strings that come with the request. >rangeRequestHandlingstring yes How to handle range requests. >hasSignedURLsbool yes Are Urls signed? >hasNegativeCachingCustomizationbool yes Any customization required for negative caching? >negativeCachingCustomizationNotestring yes Negative caching customization instructions. >serviceAliasesarray no Service aliases which will be used for this service. >rateLimitingGBPSint no Rate Limiting - Bandwidth (Gbps) >rateLimitingTPSint no Rate Limiting - Transactions/Second >overflowServicestring no An overflow point (URL or IP address) used if rate limits are met. >headerRewriteEdgestring no Headers can be added or altered at each layer of the CDN. >headerRewriteMidstring no Headers can be added or altered at each layer of the CDN. >headerRewriteRedirectRouterstring no Headers can be added or altered at each layer of the CDN. >notesstring no Additional instructions to provide the delivery service provisioning team. Request Example
{ "emailTo": "foo@bar.com", "details": { "customer": "XYZ Corporation", "contentType": "video-on-demand", "deepCachingType": "NEVER", "deliveryProtocol": "http", "routingType": "dns", "routingName": "foo", "serviceDesc": "service description goes here", "peakBPSEstimate": "less-than-5-Gbps", "peakTPSEstimate": "less-than-1000-TPS", "maxLibrarySizeEstimate": "less-than-200-GB", "originURL": "http://myorigin.com", "hasOriginDynamicRemap": false, "originTestFile": "http://myorigin.com/crossdomain.xml", "hasOriginACLWhitelist": true, "originHeaders": "", "otherOriginSecurity": "", "queryStringHandling": "ignore-in-cache-key-and-pass-up", "rangeRequestHandling": "range-requests-not-used", "hasSignedURLs": true, "hasNegativeCachingCustomization": true, "negativeCachingCustomizationNote": "negative caching instructions", "serviceAliases": [ "http://alias1.com", "http://alias2.com" ], "rateLimitingGBPS": 50, "rateLimitingTPS": 5000, "overflowService": "http://overflowcdn.com", "headerRewriteEdge": "", "headerRewriteMid": "", "headerRewriteRedirectRouter": "", "notes": "" } }
Response Properties
Parameter Type Description alertsarray A collection of alert messages. >levelstring Success, info, warning or error. >textstring Alert message. versionstring Response Example
{ "alerts": [ { "level": "success", "text": "Delivery Service request sent to foo@bar.com." } ] }
POST /api/1.2/deliveryservices
Allows user to create a delivery service.
Authentication Required: Yes
Role(s) Required: Admin or Operations
Request Properties
Parameter Required Description active yes true if active, false if inactive. anonymousBlockingEnabled no
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurl no Cache URL rule to apply to this delivery service. ccrDnsTtl no The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr.host. cdnId yes cdn id checkPath no The path portion of the URL to check this deliveryservice for health. deepCachingType no When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayName yes Display name dnsBypassCname no Bypass CNAME dnsBypassIp no The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6 no The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtl no The TTL of the DNS bypass response. dscp yes The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewrite no The EDGE header rewrite actions to perform. fqPacingRate no The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectURL no This is the URL Traffic Router will redirect to when Geo Limit Failure. geoLimit yes
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from geo limit countries
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountries no The geo limit countries. geoProvider yes
- 0: Maxmind(default)
- 1: Neustar
globalMaxMbps no The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTps no The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdn no The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. infoUrl no Use this to add a URL that points to more information about that deliveryservice. initialDispersion yes|no Initial dispersion. Required for HTTP* delivery services. ipv6RoutingEnabled yes|no false: send IPv4 address of Traffic Router to client on HTTP type del. Required for DNS*, HTTP* and STEERING* delivery services. logsEnabled yes
- false: No
- true: Yes
longDesc no Description field. longDesc1 no Description field 1. longDesc2 no Description field 2. maxDnsAnswers no The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewrite no The MID header rewrite actions to perform. missLat yes|no The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. e.g. 39.7391500 or null. Required for DNS* and HTTP* delivery services. missLong yes|no The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. e.g. -104.9847000 or null. Required for DNS* and HTTP* delivery services. multiSiteOrigin yes|no true if enabled, false if disabled. Required for DNS* and HTTP* delivery services. orgServerFqdn yes|no The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. This field is required if type is DNS* or HTTP*. originShield no Origin shield profileId no DS profile ID protocol yes|no
- 0: serve with http:// at EDGE
- 1: serve with https:// at EDGE
- 2: serve with both http:// and https:// at EDGE
Required for DNS*, HTTP* or STEERING delivery services.
qstringIgnore yes|no
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
Required for DNS* and HTTP* delivery services.
rangeRequestHandling yes|no How to treat range requests (required for DNS* and HTTP* delivery services): - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemap no Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlocking yes Is the Regional Geo Blocking feature enabled. remapText no Additional raw remap line text. routingName yes The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signed no
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithm no
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersion no SSL key version tenantId No Owning tenant ID trRequestHeaders no Traffic router log request headers trResponseHeaders no Traffic router additional response headers typeId yes The type of this deliveryservice (one of :ref:to-api-v12-types use_in_table=’deliveryservice’). xmlId yes Unique string that describes this deliveryservice. Request Example
{ "xmlId": "my_ds_1", "displayName": "my_ds_displayname_1", "tenantId": 1, "protocol": 1, "orgServerFqdn": "http://10.75.168.91", "cdnId": 2, "typeId": 42, "active": false, "dscp": 10, "geoLimit": 0, "geoProvider": 0, "initialDispersion": 1, "ipv6RoutingEnabled": false, "logsEnabled": false, "multiSiteOrigin": false, "missLat": 39.7391500, "missLong": -104.9847000, "qstringIgnore": 0, "rangeRequestHandling": 0, "regionalGeoBlocking": false, "anonymousBlockingEnabled": false, "signed": false, "signingAlgorithm": null }Response Properties
Parameter Type Description activebool true if active, false if inactive. anonymousBlockingEnabledbool
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurlstring Cache URL rule to apply to this delivery service. ccrDnsTtlint The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr. host. cdnIdint Id of the CDN to which the delivery service belongs to. cdnNamestring Name of the CDN to which the delivery service belongs to. checkPathstring The path portion of the URL to check this deliveryservice for health. deepCachingTypestring When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayNamestring The display name of the delivery service. dnsBypassCnamestring dnsBypassIpstring The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6string The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtlint The TTL of the DNS bypass response. dscpint The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewritestring The EDGE header rewrite actions to perform. exampleURLsarray Entry points into the CDN for this deliveryservice. fqPacingRateint The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectUrlstring geoLimitint
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from USA
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountriesstring geoProviderint globalMaxMbpsint The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTpsint The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdnstring The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. idint The deliveryservice id (database row number). infoUrlstring Use this to add a URL that points to more information about that deliveryservice. initialDispersionint ipv6RoutingEnabledbool false: send IPv4 address of Traffic Router to client on HTTP type del. lastUpdatedstring logsEnabledbool longDescstring Description field. longDesc1string Description field 1. longDesc2string Description field 2. matchListarray Array of matchList hashes. >>typestring The type of MatchList (one of :ref:to-api-v11-types use_in_table=’regex’). >>setNumberstring The set Number of the matchList. >>patternstring The regexp for the matchList. maxDnsAnswersint The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewritestring The MID header rewrite actions to perform. missLatfloat The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. 39.7391500 or null missLongfloat The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. -104.9847000 or null multiSiteOriginbool Is the Multi Site Origin feature enabled for this delivery service (0=false, 1=true). See Multi Site Origin orgServerFqdnstring The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. originShieldstring profileDescriptionstring The description of the Traffic Router Profile with which this deliveryservice is associated. profileIdint The id of the Traffic Router Profile with which this deliveryservice is associated. profileNamestring The name of the Traffic Router Profile with which this deliveryservice is associated. protocolint qstringIgnoreint
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
rangeRequestHandlingint How to treat range requests: - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemapstring Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlockingbool Regex Remap rule to apply to this delivery service at the Edge tier. remapTextstring Additional raw remap line text. routingNamestring The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signedbool
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithmstring
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersionint trRequestHeadersstring trResponseHeadersstring typeIdint The type of this deliveryservice (one of :ref:to-api-v11-types use_in_table=’deliveryservice’). xmlIdstring Unique string that describes this deliveryservice. Response Example
{ "response": [ { "active": true, "anonymousBlockingEnabled": false, "cacheurl": null, "ccrDnsTtl": "3600", "cdnId": "2", "cdnName": "over-the-top", "checkPath": "", "deepCachingType": "NEVER", "displayName": "My Cool Delivery Service", "dnsBypassCname": "", "dnsBypassIp": "", "dnsBypassIp6": "", "dnsBypassTtl": "30", "dscp": "40", "edgeHeaderRewrite": null, "exampleURLs": [ "http://foo.foo-ds.foo.bar.net" ], "geoLimit": "0", "geoLimitCountries": null, "geoLimitRedirectURL": null, "geoProvider": "0", "globalMaxMbps": null, "globalMaxTps": "0", "fqPacingRate": "0", "httpBypassFqdn": "", "id": "442", "infoUrl": "", "initialDispersion": "1", "ipv6RoutingEnabled": true, "lastUpdated": "2016-01-26 08:49:35", "logsEnabled": false, "longDesc": "", "longDesc1": "", "longDesc2": "", "matchList": [ { "pattern": ".*\\.foo-ds\\..*", "setNumber": "0", "type": "HOST_REGEXP" } ], "maxDnsAnswers": "0", "midHeaderRewrite": null, "missLat": "39.7391500", "missLong": "-104.9847000", "multiSiteOrigin": false, "orgServerFqdn": "http://baz.boo.net", "originShield": null, "profileDescription": "Content Router for over-the-top", "profileId": "5", "profileName": "ROUTER_TOP", "protocol": "0", "qstringIgnore": "1", "rangeRequestHandling": "0", "regexRemap": null, "regionalGeoBlocking": false, "remapText": null, "routingName": "foo", "signed": false, "signingAlgorithm": null, "sslKeyVersion": "0", "tenantId": 1, "trRequestHeaders": null, "trResponseHeaders": "Access-Control-Allow-Origin: *", "type": "HTTP", "typeId": "8", "xmlId": "foo-ds" } ] }
PUT /api/1.2/deliveryservices/{:id}
Allows user to edit a delivery service.
Authentication Required: Yes
Role(s) Required: admin or oper
Request Route Parameters
Name Required Description id yes delivery service id. Request Properties
Parameter Required Description active yes true if active, false if inactive. anonymousBlockingEnabled no
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurl no Cache URL rule to apply to this delivery service. ccrDnsTtl no The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr.host. cdnId yes cdn id checkPath no The path portion of the URL to check this deliveryservice for health. deepCachingType no When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayName yes Display name dnsBypassCname no Bypass CNAME dnsBypassIp no The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6 no The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtl no The TTL of the DNS bypass response. dscp yes The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewrite no The EDGE header rewrite actions to perform. fqPacingRate no The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectURL no This is the URL Traffic Router will redirect to when Geo Limit Failure. geoLimit yes
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from geo limit countries
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountries no The geo limit countries. geoProvider yes
- 0: Maxmind(default)
- 1: Neustar
globalMaxMbps no The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTps no The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdn no The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. infoUrl no Use this to add a URL that points to more information about that deliveryservice. initialDispersion yes|no Initial dispersion. Required for HTTP* delivery services. ipv6RoutingEnabled yes|no false: send IPv4 address of Traffic Router to client on HTTP type del. Required for DNS*, HTTP* and STEERING* delivery services. logsEnabled yes
- false: No
- true: Yes
longDesc no Description field. longDesc1 no Description field 1. longDesc2 no Description field 2. maxDnsAnswers no The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewrite no The MID header rewrite actions to perform. missLat yes|no The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. e.g. 39.7391500 or null. Required for DNS* and HTTP* delivery services. missLong yes|no The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. e.g. -104.9847000 or null. Required for DNS* and HTTP* delivery services. multiSiteOrigin yes|no true if enabled, false if disabled. Required for DNS* and HTTP* delivery services. orgServerFqdn yes|no The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. This field is required if type is DNS* or HTTP*. originShield no Origin shield profileId no DS profile ID protocol yes|no
- 0: serve with http:// at EDGE
- 1: serve with https:// at EDGE
- 2: serve with both http:// and https:// at EDGE
Required for DNS*, HTTP* or STEERING delivery services.
qstringIgnore yes|no
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
Required for DNS* and HTTP* delivery services.
rangeRequestHandling yes|no How to treat range requests (required for DNS* and HTTP* delivery services): - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemap no Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlocking yes Is the Regional Geo Blocking feature enabled. remapText no Additional raw remap line text. routingName yes The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signed no
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithm no
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersion no SSL key version tenantId No Owning tenant ID trRequestHeaders no Traffic router log request headers trResponseHeaders no Traffic router additional response headers typeId yes The type of this deliveryservice (one of :ref:to-api-v12-types use_in_table=’deliveryservice’). xmlId yes Unique string that describes this deliveryservice. This value cannot be changed on update. Request Example
{ "xmlId": "my_ds_1", "displayName": "my_ds_displayname_1", "tenantId": 1, "protocol": 1, "orgServerFqdn": "http://10.75.168.91", "cdnId": 2, "typeId": 42, "active": false, "dscp": 10, "geoLimit": 0, "geoProvider": 0, "initialDispersion": 1, "ipv6RoutingEnabled": false, "logsEnabled": false, "multiSiteOrigin": false, "missLat": 39.7391500, "missLong": -104.9847000, "qstringIgnore": 0, "rangeRequestHandling": 0, "regionalGeoBlocking": false, "anonymousBlockingEnabled": false, "signed": false, "signingAlgorithm": null }Response Properties
Parameter Type Description activebool true if active, false if inactive. anonymousBlockingEnabledbool
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurlstring Cache URL rule to apply to this delivery service. ccrDnsTtlint The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr. host. cdnIdint Id of the CDN to which the delivery service belongs to. cdnNamestring Name of the CDN to which the delivery service belongs to. checkPathstring The path portion of the URL to check this deliveryservice for health. deepCachingTypestring When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayNamestring The display name of the delivery service. dnsBypassCnamestring dnsBypassIpstring The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6string The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtlint The TTL of the DNS bypass response. dscpint The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewritestring The EDGE header rewrite actions to perform. exampleURLsarray Entry points into the CDN for this deliveryservice. fqPacingRateint The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectUrlstring geoLimitint
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from USA
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountriesstring geoProviderint globalMaxMbpsint The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTpsint The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdnstring The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. idint The deliveryservice id (database row number). infoUrlstring Use this to add a URL that points to more information about that deliveryservice. initialDispersionint ipv6RoutingEnabledbool false: send IPv4 address of Traffic Router to client on HTTP type del. lastUpdatedstring logsEnabledbool longDescstring Description field. longDesc1string Description field 1. longDesc2string Description field 2. matchListarray Array of matchList hashes. >>typestring The type of MatchList (one of :ref:to-api-v11-types use_in_table=’regex’). >>setNumberstring The set Number of the matchList. >>patternstring The regexp for the matchList. maxDnsAnswersint The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewritestring The MID header rewrite actions to perform. missLatfloat The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. 39.7391500 or null missLongfloat The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. -104.9847000 or null multiSiteOriginbool Is the Multi Site Origin feature enabled for this delivery service (0=false, 1=true). See Multi Site Origin orgServerFqdnstring The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. originShieldstring profileDescriptionstring The description of the Traffic Router Profile with which this deliveryservice is associated. profileIdint The id of the Traffic Router Profile with which this deliveryservice is associated. profileNamestring The name of the Traffic Router Profile with which this deliveryservice is associated. protocolint qstringIgnoreint
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
rangeRequestHandlingint How to treat range requests: - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemapstring Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlockingbool Regex Remap rule to apply to this delivery service at the Edge tier. remapTextstring Additional raw remap line text. routingNamestring The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signedbool
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithmstring
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersionint trRequestHeadersstring trResponseHeadersstring typeIdint The type of this deliveryservice (one of :ref:to-api-v11-types use_in_table=’deliveryservice’). xmlIdstring Unique string that describes this deliveryservice. Response Example
{ "response": [ { "active": true, "anonymousBlockingEnabled": false, "cacheurl": null, "ccrDnsTtl": "3600", "cdnId": "2", "cdnName": "over-the-top", "checkPath": "", "deepCachingType": "NEVER", "displayName": "My Cool Delivery Service", "dnsBypassCname": "", "dnsBypassIp": "", "dnsBypassIp6": "", "dnsBypassTtl": "30", "dscp": "40", "edgeHeaderRewrite": null, "exampleURLs": [ "http://foo.foo-ds.foo.bar.net" ], "geoLimit": "0", "geoLimitCountries": null, "geoLimitRedirectURL": null, "geoProvider": "0", "globalMaxMbps": null, "globalMaxTps": "0", "fqPacingRate": "0", "httpBypassFqdn": "", "id": "442", "infoUrl": "", "initialDispersion": "1", "ipv6RoutingEnabled": true, "lastUpdated": "2016-01-26 08:49:35", "logsEnabled": false, "longDesc": "", "longDesc1": "", "longDesc2": "", "matchList": [ { "pattern": ".*\\.foo-ds\\..*", "setNumber": "0", "type": "HOST_REGEXP" } ], "maxDnsAnswers": "0", "midHeaderRewrite": null, "missLat": "39.7391500", "missLong": "-104.9847000", "multiSiteOrigin": false, "orgServerFqdn": "http://baz.boo.net", "originShield": null, "profileDescription": "Content Router for over-the-top", "profileId": "5", "profileName": "ROUTER_TOP", "protocol": "0", "qstringIgnore": "1", "rangeRequestHandling": "0", "regexRemap": null, "regionalGeoBlocking": false, "remapText": null, "routingName": "foo", "signed": false, "signingAlgorithm": null, "sslKeyVersion": "0", "tenantId": 1, "trRequestHeaders": null, "trResponseHeaders": "Access-Control-Allow-Origin: *", "type": "HTTP", "typeId": "8", "xmlId": "foo-ds" } ] }
PUT /api/1.2/deliveryservices/{:id}/safe
Allows a user to edit limited fields of an assigned delivery service.
Authentication Required: Yes
Role(s) Required: users with the delivery service assigned or ops and above
Request Route Parameters
Name Required Description id yes delivery service id. Request Properties
Parameter Required Description displayName no Display name infoUrl no Use this to add a URL that points to more information about that deliveryservice. longDesc no Description field. longDesc1 no Description field 1. all other fields n/a All other fields will be silently ignored Request Example
{ "displayName": "My Cool Delivery Service", "infoUrl": "www.info.com", "longDesc": "some info about the service", "longDesc1": "the customer label" }Response Properties
Parameter Type Description activebool true if active, false if inactive. anonymousBlockingEnabledbool
- true: enable blocking clients with anonymous ips
- false: disabled
cacheurlstring Cache URL rule to apply to this delivery service. ccrDnsTtlint The TTL of the DNS response for A or AAAA queries requesting the IP address of the tr. host. cdnIdint Id of the CDN to which the delivery service belongs to. cdnNamestring Name of the CDN to which the delivery service belongs to. checkPathstring The path portion of the URL to check this deliveryservice for health. deepCachingTypestring When to do Deep Caching for this Delivery Service:
- NEVER (default)
- ALWAYS
displayNamestring The display name of the delivery service. dnsBypassCnamestring dnsBypassIpstring The IPv4 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassIp6string The IPv6 IP to use for bypass on a DNS deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. dnsBypassTtlint The TTL of the DNS bypass response. dscpint The Differentiated Services Code Point (DSCP) with which to mark downstream (EDGE -> customer) traffic. edgeHeaderRewritestring The EDGE header rewrite actions to perform. exampleURLsarray Entry points into the CDN for this deliveryservice. fqPacingRateint The maximum rate in bytes per second for each TCP connection in this delivery service. If exceeded, will be rate limited by the Linux kernel. A default value of 0 disables this feature geoLimitRedirectUrlstring geoLimitint
- 0: None - no limitations
- 1: Only route on CZF file hit
- 2: Only route on CZF hit or when from USA
Note that this does not prevent access to content or makes content secure; it just prevents routing to the content by Traffic Router.
geoLimitCountriesstring geoProviderint globalMaxMbpsint The maximum global bandwidth allowed on this deliveryservice. If exceeded, the traffic routes to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices. globalMaxTpsint The maximum global transactions per second allowed on this deliveryservice. When this is exceeded traffic will be sent to the dnsByPassIp* for DNS deliveryservices and to the httpBypassFqdn for HTTP deliveryservices httpBypassFqdnstring The HTTP destination to use for bypass on an HTTP deliveryservice - bypass starts when serving more than the globalMaxMbps traffic on this deliveryservice. idint The deliveryservice id (database row number). infoUrlstring Use this to add a URL that points to more information about that deliveryservice. initialDispersionint ipv6RoutingEnabledbool false: send IPv4 address of Traffic Router to client on HTTP type del. lastUpdatedstring logsEnabledbool longDescstring Description field. longDesc1string Description field 1. longDesc2string Description field 2. matchListarray Array of matchList hashes. >>typestring The type of MatchList (one of :ref:to-api-v11-types use_in_table=’regex’). >>setNumberstring The set Number of the matchList. >>patternstring The regexp for the matchList. maxDnsAnswersint The maximum number of IPs to put in a A/AAAA response for a DNS deliveryservice (0 means all available). midHeaderRewritestring The MID header rewrite actions to perform. missLatfloat The latitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. 39.7391500 or null missLongfloat The longitude as decimal degrees to use when the client cannot be found in the CZF or the Geo lookup. - e.g. -104.9847000 or null multiSiteOriginbool Is the Multi Site Origin feature enabled for this delivery service (0=false, 1=true). See Multi Site Origin orgServerFqdnstring The origin server base URL (FQDN when used in this instance, includes the protocol (http:// or https://) for use in retrieving content from the origin server. originShieldstring profileDescriptionstring The description of the Traffic Router Profile with which this deliveryservice is associated. profileIdint The id of the Traffic Router Profile with which this deliveryservice is associated. profileNamestring The name of the Traffic Router Profile with which this deliveryservice is associated. protocolint qstringIgnoreint
- 0: no special query string handling; it is for use in the cache-key and pass up to origin.
- 1: ignore query string in cache-key, but pass it up to parent and or origin.
- 2: drop query string at edge, and do not use it in the cache-key.
rangeRequestHandlingint How to treat range requests: - 0 Do not cache (ranges requested from files taht are already cached due to a non range request will be a HIT) - 1 Use the background_fetch plugin. - 2 Use the cache_range_requests plugin. regexRemapstring Regex Remap rule to apply to this delivery service at the Edge tier. regionalGeoBlockingbool Regex Remap rule to apply to this delivery service at the Edge tier. remapTextstring Additional raw remap line text. routingNamestring The routing name of this deliveryservice, e.g. <routingName>.<xmlId>.cdn.com. signedbool
- false: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- true: token based auth is enabled for this deliveryservice.
signingAlgorithmstring
- null: token based auth (see :ref:token-based-auth) is not enabled for this deliveryservice.
- “url_sig”: URL Sign token based auth is enabled for this deliveryservice.
- “uri_signing”: URI Signing token based auth is enabled for this deliveryservice.
sslKeyVersionint trRequestHeadersstring trResponseHeadersstring typeIdint The type of this deliveryservice (one of :ref:to-api-v11-types use_in_table=’deliveryservice’). xmlIdstring Unique string that describes this deliveryservice. Response Example
{ "response": [ { "active": true, "anonymousBlockingEnabled": false, "cacheurl": null, "ccrDnsTtl": "3600", "cdnId": "2", "cdnName": "over-the-top", "checkPath": "", "deepCachingType": "NEVER", "displayName": "My Cool Delivery Service", "dnsBypassCname": "", "dnsBypassIp": "", "dnsBypassIp6": "", "dnsBypassTtl": "30", "dscp": "40", "edgeHeaderRewrite": null, "exampleURLs": [ "http://foo.foo-ds.foo.bar.net" ], "geoLimit": "0", "geoLimitCountries": null, "geoLimitRedirectURL": null, "geoProvider": "0", "globalMaxMbps": null, "globalMaxTps": "0", "fqPacingRate": "0", "httpBypassFqdn": "", "id": "442", "infoUrl": "www.info.com", "initialDispersion": "1", "ipv6RoutingEnabled": true, "lastUpdated": "2016-01-26 08:49:35", "logsEnabled": false, "longDesc": "some info about the service", "longDesc1": "the customer label", "longDesc2": "", "matchList": [ { "pattern": ".*\\.foo-ds\\..*", "setNumber": "0", "type": "HOST_REGEXP" } ], "maxDnsAnswers": "0", "midHeaderRewrite": null, "missLat": "39.7391500", "missLong": "-104.9847000", "multiSiteOrigin": false, "orgServerFqdn": "http://baz.boo.net", "originShield": null, "profileDescription": "Content Router for over-the-top", "profileId": "5", "profileName": "ROUTER_TOP", "protocol": "0", "qstringIgnore": "1", "rangeRequestHandling": "0", "regexRemap": null, "regionalGeoBlocking": false, "remapText": null, "routingName": "foo", "signed": false, "signingAlgorithm": null, "sslKeyVersion": "0", "tenantId": 1, "trRequestHeaders": null, "trResponseHeaders": "Access-Control-Allow-Origin: *", "type": "HTTP", "typeId": "8", "xmlId": "foo-ds" } ] }
DELETE /api/1.2/deliveryservices/{:id}
Allows user to delete a delivery service.
Authentication Required: Yes
Role(s) Required: admin or oper
Request Route Parameters
Name Required Description id yes delivery service id. Response Example
{ "alerts": [ { "level": "success", "text": "Delivery service was deleted." } ], }
POST /api/1.2/deliveryservices/:xml_id/servers
Assign caches to a delivery service.
Authentication Required: Yes
Role(s) Required: admin or oper
Request Route Parameters
Name Required Description xml_id yes the xml_id of the deliveryservice Request Properties
Parameter Required Description serverNames yes array of hostname of cache servers to assign to this deliveryservice, for example: [ “server1”, “server2” ] Request Example
{ "serverNames": [ "tc1_ats1" ] }Response Properties
Parameter Type Description xml_id string Unique string that describes this delivery service. serverNames string array of hostname of cache servers to assign to this deliveryservice, for example: [ “server1”, “server2” ] Response Example
{ "response":{ "serverNames":[ "tc1_ats1" ], "xmlId":"my_ds_1" } }
URI Signing Keys¶
DELETE /api/1.2/deliveryservices/:xml_id/urisignkeys
Deletes URISigning objects for a delivery service.
Authentication Required: Yes
Role(s) Required: admin
Request Route Parameters
Name Required Description xml_id yes xml_id of the desired delivery service
GET /api/1.2/deliveryservices/:xml_id/urisignkeys
Retrieves one or more URISigning objects for a delivery service.
Authentication Required: Yes
Role(s) Required: admin
Request Route Parameters
Name Required Description xml_id yes xml_id of the desired delivery service Response Properties
Parameter Type Description Issuerstring a string describing the issuer of the URI signing object. Multiple URISigning objects may be returned in a response, see example renewal_kidstring a string naming the jwt key used for renewals. keysstring json array of jwt symmetric keys . algstring this parameter repeats for each jwt key in the array and specifies the jwa encryption algorithm to use with this key, RFC 7518. kidstring this parameter repeats for each jwt key in the array and specifies the unique id for the key as defined in RFC 7516. ktystring this parameter repeats for each jwt key in the array and specifies the key type as defined in RFC 7516. kstring this parameter repeats for each jwt key in the array and specifies the base64 encoded symmetric key see RFC 7516. Response Example
{ "Kabletown URI Authority": { "renewal_kid": "Second Key", "keys": [ { "alg": "HS256", "kid": "First Key", "kty": "oct", "k": "Kh_RkUMj-fzbD37qBnDf_3e_RvQ3RP9PaSmVEpE24AM" }, { "alg": "HS256", "kid": "Second Key", "kty": "oct", "k": "fZBpDBNbk2GqhwoB_DGBAsBxqQZVix04rIoLJ7p_RlE" } ] } }
POST /api/1.2/deliveryservices/:xml_id/urisignkeys
Assigns URISigning objects to a delivery service.
Authentication Required: Yes
Role(s) Required: admin
Request Route Parameters
Name Required Description xml_id yes xml_id of the desired delivery service Request Properties
Parameter Type Description Issuerstring a string describing the issuer of the URI signing object. Multiple URISigning objects may be returned in a response, see example renewal_kidstring a string naming the jwt key used for renewals. keysstring json array of jwt symmetric keys . algstring this parameter repeats for each jwt key in the array and specifies the jwa encryption algorithm to use with this key, RFC 7518. kidstring this parameter repeats for each jwt key in the array and specifies the unique id for the key as defined in RFC 7516. ktystring this parameter repeats for each jwt key in the array and specifies the key type as defined in RFC 7516. kstring this parameter repeats for each jwt key in the array and specifies the base64 encoded symmetric key see RFC 7516. Request Example
{ "Kabletown URI Authority": { "renewal_kid": "Second Key", "keys": [ { "alg": "HS256", "kid": "First Key", "kty": "oct", "k": "Kh_RkUMj-fzbD37qBnDf_3e_RvQ3RP9PaSmVEpE24AM" }, { "alg": "HS256", "kid": "Second Key", "kty": "oct", "k": "fZBpDBNbk2GqhwoB_DGBAsBxqQZVix04rIoLJ7p_RlE" } ] } }
PUT /api/1.2/deliveryservices/:xml_id/urisignkeys
updates URISigning objects on a delivery service.
Authentication Required: Yes
Role(s) Required: admin
Request Route Parameters
Name Required Description xml_id yes xml_id of the desired delivery service Request Properties
Parameter Type Description Issuerstring a string describing the issuer of the URI signing object. Multiple URISigning objects may be returned in a response, see example renewal_kidstring a string naming the jwt key used for renewals. keysstring json array of jwt symmetric keys . algstring this parameter repeats for each jwt key in the array and specifies the jwa encryption algorithm to use with this key, RFC 7518. kidstring this parameter repeats for each jwt key in the array and specifies the unique id for the key as defined in RFC 7516. ktystring this parameter repeats for each jwt key in the array and specifies the key type as defined in RFC 7516. kstring this parameter repeats for each jwt key in the array and specifies the base64 encoded symmetric key see RFC 7516. Request Example
{ "Kabletown URI Authority": { "renewal_kid": "Second Key", "keys": [ { "alg": "HS256", "kid": "First Key", "kty": "oct", "k": "Kh_RkUMj-fzbD37qBnDf_3e_RvQ3RP9PaSmVEpE24AM" }, { "alg": "HS256", "kid": "Second Key", "kty": "oct", "k": "fZBpDBNbk2GqhwoB_DGBAsBxqQZVix04rIoLJ7p_RlE" } ] } }