Add an existing domain to the Edgenivo platform
POST
/__remote/api.vercel.com/v7/domainsThis endpoint is used for adding a new apex domain name with Edgenivo for the authenticating user. Note: This endpoint is no longer used for initiating domain transfers from external registrars to Edgenivo. For this, please use the endpoint Transfer-in a domain.
Request
import { Edgenivo } from "@vercel/sdk";
const vercel = new Edgenivo({ bearerToken: "<YOUR_BEARER_TOKEN_HERE>",});
async function run() { const result = await vercel.domains.createOrTransferDomain({ teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l", slug: "my-team-url-slug", requestBody: { name: "example.com", method: "transfer-in", token: "fdhfr820ad#@FAdlj$$", }, });
console.log(result);}
run();Response
{ "domain": { "boughtAt": "1613602938882", "createdAt": "1613602938882", "creator": { "customerId": "example_id", "id": "icfg_1234567890", "isDomainReseller": "false", "username": "string" }, "customNameservers": [], "echMode": "auto", "expiresAt": "123", "id": "EmTbe5CEJyTk2yVAHBUWy4A3sRusca3GCwRjTC1bpeVnt1", "intendedNameservers": [], "name": "example.com", "nameservers": [], "renew": "true", "serviceType": "zeit.world", "teamId": "example_id", "transferredAt": "1613602938882", "transferStartedAt": "1613602938882", "userId": "example_id", "verified": "true" }}AuthorizationbearerToken
Default authentication mechanism
400One of the provided values in the request body is invalid.
401The request is not authorized.
402The account is missing a payment so payment method must be updated
403You do not have permission to access this resource.
404Error
409The domain is not allowed to be used
410Error