cdns/{{name}}/federations/{{ID}}
GET
Retrieves a list of federations in use by a specific CDN.
New in version 5.0.
- Auth. Required:
Yes
- Roles Required:
None
- Permissions Required:
CDN:READ, FEDERATION:READ, DELIVERY-SERVICE:READ
- Response Type:
Object
Request Structure
Name |
Description |
---|---|
name |
The name of the CDN for which the Federation identified by |
ID |
An integral, unique identifier for the Federation to be inspected |
GET /api/5.0/cdns/CDN-in-a-Box/federations/1 HTTP/1.1
Host: trafficops.infra.ciab.test
User-Agent: curl/7.62.0
Accept: */*
Cookie: mojolicious=...
Response Structure
- cname:
The CNAME used by the Federation
- deliveryService:
An object with keys that provide identifying information for the Delivery Service using this Federation
- id:
The integral, unique identifier for the Delivery Service
- xmlID:
The Delivery Service’s uniquely identifying xml_id
Changed in version 5.0: Prior to version 5, this field was known by the name
xmlId
- improperly formatted camelCase.
- description:
A human-readable description of the Federation. This can be
null
as well as an empty string.- lastUpdated:
The date and time at which this Federation was last modified, in RFC 3339 format
Changed in version 5.0: In earlier versions of the API, this field was given in Traffic Ops’s Custom Date/Time Format.
- ttl:
TTL for the
cname
, in hours
HTTP/1.1 200 OK
access-control-allow-credentials: true
access-control-allow-headers: Origin, X-Requested-With, Content-Type, Accept, Set-Cookie, Cookie
access-control-allow-methods: POST,GET,OPTIONS,PUT,DELETE
access-control-allow-origin: *
content-type: application/json
set-cookie: mojolicious=...; Path=/; HttpOnly
whole-content-sha512: SJA7G+7G5KcOfCtnE3Dq5DCobWtGRUKSppiDkfLZoG5+paq4E1aZGqUb6vGVsd+TpPg75MLlhyqfdfCHnhLX/g==
x-server-name: traffic_ops_golang/
content-length: 170
date: Wed, 05 Dec 2018 00:35:40 GMT
{ "response": {
"id": 1,
"cname": "test.quest.",
"ttl": 68,
"description": "A test federation",
"lastUpdated": "2018-12-05T00:05:16Z",
"deliveryService": {
"id": 1,
"xmlID": "demo1"
}
}}
PUT
Updates a Federation.
- Auth. Required:
Yes
- Roles Required:
“admin”
- Permissions Required:
FEDERATION:UPDATE, FEDERATION:READ, CDN:READ
- Response Type:
Object
Request Structure
Name |
Description |
---|---|
name |
The name of the CDN for which the Federation identified by |
ID |
An integral, unique identifier for the Federation to be updated |
Caution
The name of the CDN doesn’t actually matter. It doesn’t even need to be the name of any existing CDN.
- cname:
The CNAME used by the Federation
Note
The CNAME must end with a “
.
”- description:
An optional description of the federation
- ttl:
Time to Live (TTL) for the name record used for
cname
- minimum of 60Changed in version 5.0: In earlier API versions, there is no enforced minimum (although Traffic Portal would never allow a value under 60).
PUT /api/5.0/cdns/CDN-in-a-Box/federations/1 HTTP/1.1
Host: trafficops.infra.ciab.test
User-Agent: curl/7.62.0
Accept: */*
Cookie: mojolicious=...
Content-Length: 33
Content-Type: application/json
{
"cname": "foo.bar.",
"ttl": 68
}
Response Structure
- cname:
The CNAME used by the Federation
- description:
A human-readable description of the Federation. This can be
null
as well as an empty string.- lastUpdated:
The date and time at which this Federation was last modified, in RFC 3339 format
Changed in version 5.0: In earlier versions of the API, this field was given in Traffic Ops’s Custom Date/Time Format.
- ttl:
TTL for the
cname
, in hours
HTTP/1.1 200 OK
access-control-allow-credentials: true
access-control-allow-headers: Origin, X-Requested-With, Content-Type, Accept, Set-Cookie, Cookie
access-control-allow-methods: POST,GET,OPTIONS,PUT,DELETE
access-control-allow-origin: *
content-type: application/json
set-cookie: mojolicious=...; Path=/; HttpOnly
whole-content-sha512: qcjfQ+gDjNxYQ1aq+dlddgrkFWnkFYxsFF+SHDqqH0uVHBVksmU0aTFgltozek/u6wbrGoR1LFf9Fr1C1SbigA==
x-server-name: traffic_ops_golang/
content-length: 174
date: Wed, 05 Dec 2018 01:03:40 GMT
{ "alerts": [
{
"text": "Federation was updated",
"level": "success"
}
],
"response": {
"id": 1,
"cname": "foo.bar.",
"ttl": 68,
"description": null,
"lastUpdated": "2018-12-05T01:03:40Z"
}}
DELETE
Deletes a specific federation.
- Auth. Required:
Yes
- Roles Required:
“admin”
- Permissions Required:
FEDERATION:DELETE, FEDERATION:READ, CDN:READ
- Response Type:
Object
Changed in version 5.0: In earlier API versions, no response
property is present in these responses.
Request Structure
Name |
Description |
---|---|
name |
The name of the CDN for which the Federation identified by |
ID |
An integral, unique identifier for the Federation to be deleted |
Caution
The name of the CDN doesn’t actually matter. It doesn’t even need to be the name of any existing CDN.
DELETE /api/5.0/cdns/CDN-in-a-Box/federations/1 HTTP/1.1
Host: trafficops.infra.ciab.test
User-Agent: curl/7.62.0
Accept: */*
Cookie: mojolicious=...
Response Structure
- cname:
The CNAME used by the Federation
- description:
A human-readable description of the Federation. This can be
null
as well as an empty string.- lastUpdated:
The date and time at which this Federation was last modified, in RFC 3339 format
- ttl:
TTL for the
cname
, in hours
HTTP/1.1 200 OK
access-control-allow-credentials: true
access-control-allow-headers: Origin, X-Requested-With, Content-Type, Accept, Set-Cookie, Cookie
access-control-allow-methods: POST,GET,OPTIONS,PUT,DELETE
access-control-allow-origin: *
content-type: application/json
set-cookie: mojolicious=...; Path=/; HttpOnly
whole-content-sha512: Cnkfj6dmzTD3if9oiDq33tqf7CnAflKK/SPgqJyfu6HUfOjLJOgKIZvkcs2wWY6EjLVdw5qsatsd4FPoCyjvcw==
x-server-name: traffic_ops_golang/
content-length: 68
date: Wed, 05 Dec 2018 01:17:24 GMT
{ "alerts": [
{
"text": "Federation was deleted",
"level": "success"
}
],
"response": {
"id": 1,
"cname": "foo.bar.",
"ttl": 68,
"description": null,
"lastUpdated": "2018-12-05T01:03:40Z"
}}