# Organization API: Customer Portal: Custom domain

> The 5 Organization API operations for custom domain.

Source: https://docs.coritan.com/api/reference/organizations/customer-portal/external-servers-custom-domain/

Part of [Customer Portal](/api/reference/organizations/customer-portal/).

## Operations

| Method | Path | Summary |
| --- | --- | --- |
| GET | [`/api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`](#op-get-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain) | Get custom domain |
| POST | [`/api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`](#op-post-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain) | Link custom domain |
| PATCH | [`/api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`](#op-patch-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain) | Show the vanity hostname, or the hosted one, in the public server list |
| DELETE | [`/api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`](#op-delete-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain) | Unlink custom domain |
| POST | [`/api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain/verify`](#op-post-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain-verif) | Check the CNAME now rather than waiting for the next maintenance pass |

### Get custom domain {#op-get-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain}

`GET /api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`

#### Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| `service_id` | path | integer | yes |
| `org_slug` | path | string | yes |

#### Responses

| Status | Meaning |
| --- | --- |
| `200` | Success. |
| `422` | The request is not valid. `detail` lists each problem. |

### Link custom domain {#op-post-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain}

`POST /api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`

#### Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| `service_id` | path | integer | yes |
| `org_slug` | path | string | yes |

#### Request body

`application/json` (required)

| Field | Type | Required |
| --- | --- | --- |
| `domain` | string | yes |
| `subdomain` | string | no |
| `include_in_list` | boolean | no |

#### Responses

| Status | Meaning |
| --- | --- |
| `200` | Success. |
| `422` | The request is not valid. `detail` lists each problem. |

### Show the vanity hostname, or the hosted one, in the public server list {#op-patch-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain}

`PATCH /api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`

Show the vanity hostname, or the hosted one, in the public server list.

#### Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| `service_id` | path | integer | yes |
| `org_slug` | path | string | yes |

#### Request body

`application/json` (required)

| Field | Type | Required |
| --- | --- | --- |
| `include_in_list` | boolean | yes |

#### Responses

| Status | Meaning |
| --- | --- |
| `200` | Success. |
| `422` | The request is not valid. `detail` lists each problem. |

### Unlink custom domain {#op-delete-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain}

`DELETE /api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain`

#### Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| `service_id` | path | integer | yes |
| `org_slug` | path | string | yes |

#### Responses

| Status | Meaning |
| --- | --- |
| `200` | Success. |
| `422` | The request is not valid. `detail` lists each problem. |

### Check the CNAME now rather than waiting for the next maintenance pass {#op-post-api-v1-orgs-org-slug-portal-external-servers-service-id-custom-domain-verif}

`POST /api/v1/orgs/{org_slug}/portal/external-servers/{service_id}/custom-domain/verify`

Check the CNAME now rather than waiting for the next maintenance pass.

#### Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| `service_id` | path | integer | yes |
| `org_slug` | path | string | yes |

#### Responses

| Status | Meaning |
| --- | --- |
| `200` | Success. |
| `422` | The request is not valid. `detail` lists each problem. |
