Get the auth code for a domain
GET
https://api.vercel.com/v1/registrar/domains/{domain}/auth-codeGet the auth code for a domain. This is required to transfer a domain from Vercel to another registrar.
https://api.vercel.com/v1/registrar/domains/{domain}/auth-code
const response = await fetch('https://api.vercel.com/v1/registrar/domains/domain/auth-code?teamId=string', { method: 'GET', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', },});
const data = await response.json();console.log(data);Response
{ "authCode": "string"}Errors
{ "status": "400", "code": "domain_not_registered", "message": "string"}AuthorizationbearerToken
Default authentication mechanism
400There was something wrong with the request
404The domain was not found in our system.
409The domain cannot be transfered out until the specified date.
429TooManyRequests