# Create a TXT Domain Record

{% hint style="info" %}
**Prerequisites:**

* The request for domain ownership using the [<mark style="color:blue;">API</mark>](https://docs.ionos.com/sections-test/guides/set-up-ionos-cloud/management/identity-access-management/iam-federation/api-how-tos/request-domain-ownership) must be complete.
* The organization uses [<mark style="color:blue;">IONOS Cloud DNS</mark>](https://docs.ionos.com/sections-test/guides/network-services/cloud-dns) to publish the Domain Name System (DNS).
  {% endhint %}

{% hint style="info" %}
**Note:** If your organization uses any other domain provider, contact your provider to locate the DNS settings and add the `TXT` record value by referring to the steps in this guide.
{% endhint %}

You must add the `token` value provided in the [<mark style="color:blue;">Request Domain Ownership API</mark>](https://docs.ionos.com/sections-test/guides/set-up-ionos-cloud/management/identity-access-management/iam-federation/api-how-tos/request-domain-ownership) response to the `TXT Domain Record`.

You can create a record of type `TXT` by following these steps:

1\. In the DCD, go to **Menu** > **Network Services** > **Cloud DNS** > **Public zones** tab.

2\. Select **Primary Zones** from the drop-down list.

3\. Select the appropriate primary zone in the **DNS ZONES** column to create records. Alternatively, click **Details & Records** in the **ACTIONS** column.

![Zone selection](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-85b510ea4adb54496925ce3dbaebb38f8505ebfe%2Fzones-overview.png?alt=media)

4\. Click **Create record** in the **Details & Records** window.

5\. Enter the following details in the **Create Record** window:

* **Enabled/Disabled:** Set it to either **Enabled** (by default) or **Disabled**.
* **Name:** Leave the name value empty for your DNS record. It helps to identify the domain associated with the token by the domain name.
* **TTL:** Enter an appropriate Time-To-Live (TTL) setting for your DNS record in seconds. The default value is 3600 seconds.
* **Type:** Select the record type as `TXT`.
* **Content:** Enter the `token` value provided in the API response as the content value. Example: `9019680770992564882066368772815872312262977566198195`.
* **Preview:** Ensure that the details of the record to be created are accurate.&#x20;

![Define Cloud DNS record properties](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-7c8d5affa5c45e0f559a2558ee22cca27148b27d%2Fiam-federation-create-dns-record.png?alt=media)

6\. Click **Save** to create the DNS record.

{% hint style="success" %}
**Result:** Your DNS record of type `TXT` is successfully created.
{% endhint %}

## Next steps

* After creating the TXT Domain Record, you must manually trigger the domain ownership verification using the [<mark style="color:blue;">Verify Domain Ownership</mark>](https://docs.ionos.com/sections-test/guides/set-up-ionos-cloud/management/identity-access-management/iam-federation/api-how-tos/verify-domain-ownership) API. This endpoint will only change the domain status to **Approved** when the TXT Record contains the provided token. The duration of this process ranges from a few seconds to up to a week, depending on your domain provider.

{% hint style="info" %}
**Note:** It is recommended to use the command `dig +short {yourdomain} TXT` to confirm the presence of the token before triggering verification.
{% endhint %}

* You can verify the domain ownership status by using the [<mark style="color:blue;">Retrieve Domain</mark>](https://docs.ionos.com/sections-test/guides/set-up-ionos-cloud/management/identity-access-management/iam-federation/api-how-tos/retrieve-domain) API.
