Claim Domain Ownership
POST
https://api.vercel.com/v9/domains/{domain}/claimClaim ownership of a domain for the authenticated team by verifying a TXT record. The caller must first add a TXT record to
_vercel.{domain} (obtained from GET /domains/:domain/verification), then call this endpoint to complete the ownership transfer. If the TXT record is verified, the domain ownership will be transferred to the caller's team, even if the domain is currently owned by another user or team.https://api.vercel.com/v9/domains/{domain}/claim
const response = await fetch('https://api.vercel.com/v9/domains/domain/claim?teamId=string&slug=string', { method: 'POST', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', },});
const data = await response.json();console.log(data);Response
{ "domain": { "boughtAt": "1613602938882", "createdAt": "1613602938882", "creator": { "customerId": "example_id", "email": "user@example.com", "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