get method
Gets the contents of a resource file.
For more information about resource files, see Resource files.
Request parameters:
parent
- Required. Name of the environment in the following format:
organizations/{org}/environments/{env}
.
Value must have pattern ^organizations/\[^/\]+/environments/\[^/\]+$
.
type
- Required. Resource file type. {{ resource_file_type }}
name
- Required. ID of the resource file. Must match the regular
expression: [a-zA-Z0-9:/\!@#$%^&{}[]()+-=,.~'` ]{1,255}
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a GoogleApiHttpBody.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<GoogleApiHttpBody> get(
core.String parent,
core.String type,
core.String name, {
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if ($fields != null) 'fields': [$fields],
};
final url_ = 'v1/' +
core.Uri.encodeFull('$parent') +
'/resourcefiles/' +
commons.escapeVariable('$type') +
'/' +
commons.escapeVariable('$name');
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return GoogleApiHttpBody.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}