* *

* For more information about this service, see the API * Documentation *

* * @author Google, Inc. */ class Dns extends \Google\Service { /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */ const CLOUD_PLATFORM = "https://www.googleapis.com/auth/cloud-platform"; /** View your data across Google Cloud services and see the email address of your Google Account. */ const CLOUD_PLATFORM_READ_ONLY = "https://www.googleapis.com/auth/cloud-platform.read-only"; /** View your DNS records hosted by Google Cloud DNS. */ const NDEV_CLOUDDNS_READONLY = "https://www.googleapis.com/auth/ndev.clouddns.readonly"; /** View and manage your DNS records hosted by Google Cloud DNS. */ const NDEV_CLOUDDNS_READWRITE = "https://www.googleapis.com/auth/ndev.clouddns.readwrite"; public $changes; public $dnsKeys; public $managedZoneOperations; public $managedZones; public $policies; public $projects; public $resourceRecordSets; public $responsePolicies; public $responsePolicyRules; /** * Constructs the internal representation of the Dns service. * * @param Client|array $clientOrConfig The client used to deliver requests, or a * config array to pass to a new Client instance. * @param string $rootUrl The root URL used for requests to the service. */ public function __construct($clientOrConfig = [], $rootUrl = null) { parent::__construct($clientOrConfig); $this->rootUrl = $rootUrl ?: 'https://dns.googleapis.com/'; $this->servicePath = ''; $this->batchPath = 'batch'; $this->version = 'v2'; $this->serviceName = 'dns'; $this->changes = new Dns\Resource\Changes( $this, $this->serviceName, 'changes', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/changes', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/changes/{changeId}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'changeId' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/changes', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], 'sortBy' => [ 'location' => 'query', 'type' => 'string', ], 'sortOrder' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->dnsKeys = new Dns\Resource\DnsKeys( $this, $this->serviceName, 'dnsKeys', [ 'methods' => [ 'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/dnsKeys/{dnsKeyId}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'dnsKeyId' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], 'digestType' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/dnsKeys', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'digestType' => [ 'location' => 'query', 'type' => 'string', ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->managedZoneOperations = new Dns\Resource\ManagedZoneOperations( $this, $this->serviceName, 'managedZoneOperations', [ 'methods' => [ 'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/operations/{operation}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'operation' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/operations', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], 'sortBy' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->managedZones = new Dns\Resource\ManagedZones( $this, $this->serviceName, 'managedZones', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'delete' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}', 'httpMethod' => 'DELETE', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'dnsName' => [ 'location' => 'query', 'type' => 'string', ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], ], ],'patch' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}', 'httpMethod' => 'PATCH', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'update' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}', 'httpMethod' => 'PUT', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->policies = new Dns\Resource\Policies( $this, $this->serviceName, 'policies', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'delete' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies/{policy}', 'httpMethod' => 'DELETE', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'policy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies/{policy}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'policy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], ], ],'patch' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies/{policy}', 'httpMethod' => 'PATCH', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'policy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'update' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/policies/{policy}', 'httpMethod' => 'PUT', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'policy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->projects = new Dns\Resource\Projects( $this, $this->serviceName, 'projects', [ 'methods' => [ 'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->resourceRecordSets = new Dns\Resource\ResourceRecordSets( $this, $this->serviceName, 'resourceRecordSets', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/rrsets', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'delete' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/rrsets/{name}/{type}', 'httpMethod' => 'DELETE', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'name' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'type' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/rrsets/{name}/{type}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'name' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'type' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/rrsets', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'name' => [ 'location' => 'query', 'type' => 'string', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], 'type' => [ 'location' => 'query', 'type' => 'string', ], ], ],'patch' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/managedZones/{managedZone}/rrsets/{name}/{type}', 'httpMethod' => 'PATCH', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'managedZone' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'name' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'type' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->responsePolicies = new Dns\Resource\ResponsePolicies( $this, $this->serviceName, 'responsePolicies', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'delete' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}', 'httpMethod' => 'DELETE', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], ], ],'patch' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}', 'httpMethod' => 'PATCH', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'update' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}', 'httpMethod' => 'PUT', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); $this->responsePolicyRules = new Dns\Resource\ResponsePolicyRules( $this, $this->serviceName, 'responsePolicyRules', [ 'methods' => [ 'create' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules', 'httpMethod' => 'POST', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'delete' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules/{responsePolicyRule}', 'httpMethod' => 'DELETE', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicyRule' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'get' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules/{responsePolicyRule}', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicyRule' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'list' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules', 'httpMethod' => 'GET', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'maxResults' => [ 'location' => 'query', 'type' => 'integer', ], 'pageToken' => [ 'location' => 'query', 'type' => 'string', ], ], ],'patch' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules/{responsePolicyRule}', 'httpMethod' => 'PATCH', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicyRule' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ],'update' => [ 'path' => 'dns/v2/projects/{project}/locations/{location}/responsePolicies/{responsePolicy}/rules/{responsePolicyRule}', 'httpMethod' => 'PUT', 'parameters' => [ 'project' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'location' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicy' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'responsePolicyRule' => [ 'location' => 'path', 'type' => 'string', 'required' => true, ], 'clientOperationId' => [ 'location' => 'query', 'type' => 'string', ], ], ], ] ] ); } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(Dns::class, 'Google_Service_Dns');