1<?php 2/* 3 * Copyright 2014 Google Inc. 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not 6 * use this file except in compliance with the License. You may obtain a copy of 7 * the License at 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14 * License for the specific language governing permissions and limitations under 15 * the License. 16 */ 17 18/** 19 * Service definition for People (v1). 20 * 21 * <p> 22 * Provides access to information about profiles and contacts.</p> 23 * 24 * <p> 25 * For more information about this service, see the API 26 * <a href="https://developers.google.com/people/" target="_blank">Documentation</a> 27 * </p> 28 * 29 * @author Google, Inc. 30 */ 31class Google_Service_People extends Google_Service 32{ 33 /** Manage your contacts. */ 34 const CONTACTS = 35 "https://www.googleapis.com/auth/contacts"; 36 /** View your contacts. */ 37 const CONTACTS_READONLY = 38 "https://www.googleapis.com/auth/contacts.readonly"; 39 /** Know the list of people in your circles, your age range, and language. */ 40 const PLUS_LOGIN = 41 "https://www.googleapis.com/auth/plus.login"; 42 /** View your street addresses. */ 43 const USER_ADDRESSES_READ = 44 "https://www.googleapis.com/auth/user.addresses.read"; 45 /** View your complete date of birth. */ 46 const USER_BIRTHDAY_READ = 47 "https://www.googleapis.com/auth/user.birthday.read"; 48 /** View your email addresses. */ 49 const USER_EMAILS_READ = 50 "https://www.googleapis.com/auth/user.emails.read"; 51 /** View your phone numbers. */ 52 const USER_PHONENUMBERS_READ = 53 "https://www.googleapis.com/auth/user.phonenumbers.read"; 54 /** View your email address. */ 55 const USERINFO_EMAIL = 56 "https://www.googleapis.com/auth/userinfo.email"; 57 /** View your basic profile info. */ 58 const USERINFO_PROFILE = 59 "https://www.googleapis.com/auth/userinfo.profile"; 60 61 public $people; 62 public $people_connections; 63 64 /** 65 * Constructs the internal representation of the People service. 66 * 67 * @param Google_Client $client 68 */ 69 public function __construct(Google_Client $client) 70 { 71 parent::__construct($client); 72 $this->rootUrl = 'https://people.googleapis.com/'; 73 $this->servicePath = ''; 74 $this->version = 'v1'; 75 $this->serviceName = 'people'; 76 77 $this->people = new Google_Service_People_Resource_People( 78 $this, 79 $this->serviceName, 80 'people', 81 array( 82 'methods' => array( 83 'get' => array( 84 'path' => 'v1/{+resourceName}', 85 'httpMethod' => 'GET', 86 'parameters' => array( 87 'resourceName' => array( 88 'location' => 'path', 89 'type' => 'string', 90 'required' => true, 91 ), 92 'requestMask.includeField' => array( 93 'location' => 'query', 94 'type' => 'string', 95 ), 96 ), 97 ),'getBatchGet' => array( 98 'path' => 'v1/people:batchGet', 99 'httpMethod' => 'GET', 100 'parameters' => array( 101 'requestMask.includeField' => array( 102 'location' => 'query', 103 'type' => 'string', 104 ), 105 'resourceNames' => array( 106 'location' => 'query', 107 'type' => 'string', 108 'repeated' => true, 109 ), 110 ), 111 ), 112 ) 113 ) 114 ); 115 $this->people_connections = new Google_Service_People_Resource_PeopleConnections( 116 $this, 117 $this->serviceName, 118 'connections', 119 array( 120 'methods' => array( 121 'list' => array( 122 'path' => 'v1/{+resourceName}/connections', 123 'httpMethod' => 'GET', 124 'parameters' => array( 125 'resourceName' => array( 126 'location' => 'path', 127 'type' => 'string', 128 'required' => true, 129 ), 130 'sortOrder' => array( 131 'location' => 'query', 132 'type' => 'string', 133 ), 134 'requestSyncToken' => array( 135 'location' => 'query', 136 'type' => 'boolean', 137 ), 138 'pageToken' => array( 139 'location' => 'query', 140 'type' => 'string', 141 ), 142 'pageSize' => array( 143 'location' => 'query', 144 'type' => 'integer', 145 ), 146 'requestMask.includeField' => array( 147 'location' => 'query', 148 'type' => 'string', 149 ), 150 'syncToken' => array( 151 'location' => 'query', 152 'type' => 'string', 153 ), 154 ), 155 ), 156 ) 157 ) 158 ); 159 } 160} 161