WebResource

A WebResource is a representation of a verified website or domain.

It contains the canonical ID of a site or domain, the URL or domain name, and a list of owners. Note that the owners list always includes the authenticated user, because the only people who can access a WebResource are authenticated users who are owners of that site or domain.

For a list of methods for this resource, see the end of this page.

Resource representations

{
  "id": string,
  "site": {
    "type": string,
    "identifier": string
  },
  "owners": [
    string
  ]
}
Property name Value Description Notes
id string  The string used to identify this site. This value should be used in the id portion of the REST URL for the get, update, and delete operations.
owners[] list The email addresses of all direct, verified owners of this exact property. Indirect owners—for example verified owners of the containing domain—are not included in this list.
site object Container for the address and type of a site that is verified or will be verified.
site.identifier string The site identifier, which takes different forms depending on the value of the type property.
site.type string The site type.

Acceptable values are:
  • "ANDROID_APP": Set identifier to an Android app URL. Example: "android-app://com.google.android.youtube/"
  • "INET_DOMAIN": Set identifier to a domain name. Examples: "www.example.com", "example.com" or "subdomain.example.com"
  • "SITE": Set identifier to a fully-qualified URL for your site root, ending in a / mark. Examples: "https://www.example.com/" or "https://www.example.com/subsite/" 

Methods

Use the insert method to verify the authenticated user's ownership of a website or domain. Use the getupdateand delete methods to retrieve or modify a resource that has already been verified for the authenticated user.

You can see all verified resources for the authenticated user with list, and you can get a token to place on the authenticated user's site with getToken.

delete
Unverifies the user's ownership of a website or domain.
get
Retrieves the most current data for a website or domain.
getToken
Gets a verification token for the authenticated user to place on a website or domain.
insert
Verifies ownership of a website or domain.
list
Gets the list of the authenticated user's verified websites and domains.
update
Modifies the list of owners for a website or domain.