> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # GetConnectedDomain # Package: connectedDomains # Namespace: ConnectedDomainService # Method link: https://dev.wix.com/docs/api-reference/account-level/domains/connected-domains/connected-domain-v1/get-connected-domain.md ## Introduction Retrieves a connected domain. You must pass the relevant Wix account ID in the header of the call. > __Important:__ This call requires an account level API key and cannot be authenticated with the standard authorization header. --- ## REST API ### Schema ``` Method: getConnectedDomain Description: Retrieves a connected domain. You must pass the relevant Wix account GUID in the header of the call. > __Important:__ This call requires an account level API key and cannot be authenticated with the standard authorization header. URL: https://www.wixapis.com/domains/v1/connected-domains/{connectedDomainId} Method: GET # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: connectedDomainId Method parameters: param name: connectedDomainId | type: none | required: true Return type: GetConnectedDomainResponse - name: connectedDomain | type: ConnectedDomain | description: Retrieved connected domain. - name: id | type: string | description: GUID of the connected domain. Identical to the domain name including TLD. - name: domain | type: string | description: Domain name including TLD. Both root domains and subdomains are supported. - name: connectionType | type: ConnectionType | description: How the domain is connected to the Wix site. - enum: - POINTING: The domain is connected by pointing. Wix doesn't manage DNS information. - NAMESERVERS: The domain is connected by nameservers. Wix manages DNS information. - HIDDEN: The domain isn't visible to site visitors. - name: siteInfo | type: SiteInfo | description: Information about the site to which the domain is assigned, and whether it's the primary domain or a redirect. - name: id | type: string | description: GUID of the site to which the domain is assigned. - name: assignmentType | type: AssignmentType | description: The relationship assigned for this domain to the site. Read more about [primary and redirected domains](https://support.wix.com/en/article/switching-your-primary-and-redirected-domains). - enum: - PRIMARY: The singular primary domain for a site. When this type is assigned, this domain will lead directly to the site. - REDIRECT: A redirect domain for a site. Each site can have multiple redirect domains. When this type is assigned, this domain will redirect to the primary domain. - name: suppressNotifications | type: boolean | description: Whether the site owner receives standard email notifications from Wix about the connected domain. Default: `false` - name: dnsPropagationStatus | type: DnsPropagationStatus | description: DNS propagation status. - enum: - COMPLETED: The domain's DNS propagation process has successfully finished. - FAILED: The domain's DNS propagation process has failed. - IN_PROGRESS: The domain's DNS propagation process has started but hasn't successfully completed yet. - name: createdDate | type: string | description: Date and time the `connectedDomain` object was created in `YYYY-MM-DDThh:mm:ss.sssZ` format. - name: updatedDate | type: string | description: Date and time the `connectedDomain` object was last updated in `YYYY-MM-DDThh:mm:ss.sssZ` format. ``` ### Examples ### Retrieve a connected domain. ```curl curl -X GET 'https://www.wixapis.com/domains/v1/connected-domains/mysite.com' \ -H 'wix-account-id: ' \ -H 'Authorization: ' \ ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.connectedDomains.ConnectedDomainService.getConnectedDomain(connectedDomainId) Description: Retrieves a connected domain. You must pass the relevant Wix account GUID in the header of the call. > __Important:__ This call requires an account level API key and cannot be authenticated with the standard authorization header. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: connectedDomainId Method parameters: param name: connectedDomainId | type: string | description: GUID of the connected domain. Identical to the domain name including TLD. | required: true Return type: PROMISE - name: _id | type: string | description: GUID of the connected domain. Identical to the domain name including TLD. - name: domain | type: string | description: Domain name including TLD. Both root domains and subdomains are supported. - name: connectionType | type: ConnectionType | description: How the domain is connected to the Wix site. - enum: - POINTING: The domain is connected by pointing. Wix doesn't manage DNS information. - NAMESERVERS: The domain is connected by nameservers. Wix manages DNS information. - HIDDEN: The domain isn't visible to site visitors. - name: siteInfo | type: SiteInfo | description: Information about the site to which the domain is assigned, and whether it's the primary domain or a redirect. - name: _id | type: string | description: GUID of the site to which the domain is assigned. - name: assignmentType | type: AssignmentType | description: The relationship assigned for this domain to the site. Read more about [primary and redirected domains](https://support.wix.com/en/article/switching-your-primary-and-redirected-domains). - enum: - PRIMARY: The singular primary domain for a site. When this type is assigned, this domain will lead directly to the site. - REDIRECT: A redirect domain for a site. Each site can have multiple redirect domains. When this type is assigned, this domain will redirect to the primary domain. - name: suppressNotifications | type: boolean | description: Whether the site owner receives standard email notifications from Wix about the connected domain. Default: `false` - name: dnsPropagationStatus | type: DnsPropagationStatus | description: DNS propagation status. - enum: - COMPLETED: The domain's DNS propagation process has successfully finished. - FAILED: The domain's DNS propagation process has failed. - IN_PROGRESS: The domain's DNS propagation process has started but hasn't successfully completed yet. - name: _createdDate | type: Date | description: Date and time the `connectedDomain` object was created in `YYYY-MM-DDThh:mm:ss.sssZ` format. - name: _updatedDate | type: Date | description: Date and time the `connectedDomain` object was last updated in `YYYY-MM-DDThh:mm:ss.sssZ` format. ``` ### Examples ### Get a connected domain with an API key ```javascript import { createClient, ApiKeyStrategy } from "@wix/sdk"; import { connectedDomains } from "@wix/domains"; const wixClient = createClient({ modules: { connectedDomains }, auth: ApiKeyStrategy({ siteId: "MY-SITE-ID", apiKey: "MY-API-KEY", }), }); async function getConnectedDomain(connectedDomainId) { const response = await wixClient.connectedDomains.getConnectedDomain(connectedDomainId); } ``` ### getConnectedDomain (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { connectedDomains } from '@wix/domains'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { connectedDomains }, // Include the auth strategy and host as relevant }); async function getConnectedDomain(connectedDomainId) { const response = await myWixClient.connectedDomains.getConnectedDomain(connectedDomainId); }; ``` ---