Page Summary
-
Retrieves a verification token for website or domain ownership verification upon authorization.
-
Supports various verification methods including
ANALYTICS,DNS,DNS_CNAME,DNS_TXT,FILE,META, andTAG_MANAGER. -
Requires specifying the site type (
SITE,INET_DOMAIN, orANDROID_APP) and identifier (URL or domain name). -
Returns the selected verification method and the corresponding token to be placed on the site.
-
Authorization is required with the
siteverificationorsiteverification.verify_onlyscope.
Requires authorization
Gets a verification token for the authenticated user to place on a website or domain. Try it now .
Request
HTTP request
POST https://www.googleapis.com/siteVerification/v1/token
Authorization
This request requires authorization with at least one of the following scopes ( read more about authentication and authorization ).
| Scope |
|---|
https://www.googleapis.com/auth/siteverification
|
https://www.googleapis.com/auth/siteverification.verify_only
|
Request body
In the request body, supply data with the following structure:
{ "site" : { "type" : string , "identifier" : string } , "verificationMethod" : string }
site
object
site.
type
string
Acceptable values are:
- "
ANDROID_APP" - "
INET_DOMAIN" - "
SITE"
site.
identifier
string
SITE
, the identifier is a URL. If the type is set to INET_DOMAIN
, the identifier is a domain name.verificationMethod
string
Acceptable values are:
- "
ANALYTICS": Sites only - "
DNS": Use DNS_TXT instead - "
DNS_CNAME": Domains only - "
DNS_TXT": Domains only - "
FILE": Sites only - "
META": Sites only - "
TAG_MANAGER": Sites only
Response
If successful, this method returns a response body with the following structure:
{ "method": string , "token": string }
method
string
Acceptable values are:
- "
ANALYTICS" - "
DNS" - "
DNS_CNAME" - "
DNS_TXT" - "
FILE" - "
META" - "
TAG_MANAGER"
token
string
Try it!
Use the APIs Explorer below to call this method on live data and see the response. Alternatively, try the standalone Explorer .

