@@ -162,7 +162,7 @@ def make_request(self, method, url, data=None, content_type=None,
162162 return self .http .request (uri = url , method = method , headers = headers ,
163163 body = data )
164164
165- def api_request (self , method , path = None , query_params = None ,
165+ def api_request (self , method , path , query_params = None ,
166166 data = None , content_type = None ,
167167 api_base_url = None , api_version = None ,
168168 expect_json = True ):
@@ -174,32 +174,40 @@ def api_request(self, method, path=None, query_params=None,
174174
175175 :type method: string
176176 :param method: The HTTP method name (ie, ``GET``, ``POST``, etc).
177+ Required.
177178
178179 :type path: string
179180 :param path: The path to the resource (ie, ``'/b/bucket-name'``).
181+ Required.
180182
181183 :type query_params: dict
182184 :param query_params: A dictionary of keys and values to insert into
183- the query string of the URL.
185+ the query string of the URL. Default is empty dict.
184186
185187 :type data: string
186- :param data: The data to send as the body of the request.
188+ :param data: The data to send as the body of the request. Default is the
189+ empty string.
187190
188191 :type content_type: string
189- :param content_type: The proper MIME type of the data provided.
192+ :param content_type: The proper MIME type of the data provided. Default
193+ is None.
190194
191195 :type api_base_url: string
192196 :param api_base_url: The base URL for the API endpoint.
193197 Typically you won't have to provide this.
198+ Default is the standard API base URL.
194199
195200 :type api_version: string
196201 :param api_version: The version of the API to call.
197202 Typically you shouldn't provide this and instead
198203 use the default for the library.
204+ Default is the latest API version supported by
205+ gcloud-python.
199206
200207 :type expect_json: bool
201208 :param expect_json: If True, this method will try to parse the response
202209 as JSON and raise an exception if that cannot be done.
210+ Default is True.
203211
204212 :raises: Exception if the response code is not 200 OK.
205213 """
0 commit comments