Domains are used to map a request to a service inside your applications environment.
Returns a list of domain resources associated with the current application.
GET /rest/applications/43678cada57a6b839653929905ff90129ab78c9e64cb6f5756ccacabc1f34a59/domains
[
{
"domain": "demo.d9tready.com",
"port": "8080",
"certificate": "New Cert (PK: My Key)",
"force_ssl": false,
"links":
{
"href": "https://d9tready.com/rest/applications/43678cada57a6b839653929905ff90129ab78c9e64cb6f5756ccacabc1f34a59/domains/demo.d9tready.com",
"rel": "self"
}
},
...
]
| Status Code | Description |
|---|---|
| 200 OK | No error, operation successful |
| 403 FORBIDDEN | Authentication failure |
| 503 SERVICE UNAVAILABLE | Service not/partially reachable |
Retrieve a single domain resources.
GET /rest/applications/43678cada57a6b839653929905ff90129ab78c9e64cb6f5756ccacabc1f34a59/domains/demo.d9tready.com
{
"domain": "demo.d9tready.com",
"port": "8080",
"certificate": "New Cert (PK: My Key)",
"force_ssl": false
}
| Status Code | Description |
|---|---|
| 200 OK | No error, operation successful |
| 403 FORBIDDEN | Authentication failure |
| 404 NOT FOUND | Resource not found |
| 503 SERVICE UNAVAILABLE | Service not/partially reachable |
Add a domain to the application.
POST /rest/applications/43678cada57a6b839653929905ff90129ab78c9e64cb6f5756ccacabc1f34a59/domains
{
"domain": "<DOMAIN>",
"port": "<PORT>",
"tlsCertificate": "<CERTIFICATE_ID>",
"forceSsl": true|false
}
On successful creation the URL to the new domain resource is set in the Location-Header.
HTTP/1.0 201 CREATED
Location: https://d9tready.com/rest/applications/<CONTAINER_ID>/domains/<DOMAIN>
| Status Code | Description |
|---|---|
| 201 CREATED | Successful creation of resource |
| 400 BAD REQUEST | Malformed syntax or bad query |
| 403 FORBIDDEN | Authentication failure |