getProjects method

Future<GoogleCloudIdentitytoolkitV1GetProjectConfigResponse> getProjects({
  1. String? androidPackageName,
  2. String? clientId,
  3. String? delegatedProjectNumber,
  4. String? firebaseAppId,
  5. String? iosBundleId,
  6. String? projectNumber,
  7. bool? returnDynamicLink,
  8. String? sha1Cert,
  9. String? $fields,
})

Gets a project's public Identity Toolkit configuration.

(Legacy) This method also supports authenticated calls from a developer to retrieve non-public configuration.

Request parameters:

androidPackageName - Android package name to check against the real android package name. If this field is provided, and sha1_cert_hash is not provided, the action will throw an error if this does not match the real android package name.

clientId - The RP OAuth client ID. If set, a check will be performed to ensure that the OAuth client is valid for the retrieved project and the request rejected with a client error if not valid.

delegatedProjectNumber - Project Number of the delegated project request. This field should only be used as part of the Firebase V1 migration.

firebaseAppId - The Firebase app ID, for applications that use Firebase. This can be found in the Firebase console for your project. If set, a check will be performed to ensure that the app ID is valid for the retrieved project. If not valid, the request will be rejected with a client error.

iosBundleId - iOS bundle id to check against the real ios bundle id. If this field is provided, the action will throw an error if this does not match the real iOS bundle id.

projectNumber - Project number of the configuration to retrieve. This field is deprecated and should not be used by new integrations.

returnDynamicLink - Whether dynamic link should be returned.

sha1Cert - SHA-1 Android application cert hash. If set, a check will be performed to ensure that the cert hash is valid for the retrieved project and android_package_name.

$fields - Selector specifying which fields to include in a partial response.

Completes with a GoogleCloudIdentitytoolkitV1GetProjectConfigResponse.

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<GoogleCloudIdentitytoolkitV1GetProjectConfigResponse>
    getProjects({
  core.String? androidPackageName,
  core.String? clientId,
  core.String? delegatedProjectNumber,
  core.String? firebaseAppId,
  core.String? iosBundleId,
  core.String? projectNumber,
  core.bool? returnDynamicLink,
  core.String? sha1Cert,
  core.String? $fields,
}) async {
  final _queryParams = <core.String, core.List<core.String>>{
    if (androidPackageName != null)
      'androidPackageName': [androidPackageName],
    if (clientId != null) 'clientId': [clientId],
    if (delegatedProjectNumber != null)
      'delegatedProjectNumber': [delegatedProjectNumber],
    if (firebaseAppId != null) 'firebaseAppId': [firebaseAppId],
    if (iosBundleId != null) 'iosBundleId': [iosBundleId],
    if (projectNumber != null) 'projectNumber': [projectNumber],
    if (returnDynamicLink != null)
      'returnDynamicLink': ['${returnDynamicLink}'],
    if (sha1Cert != null) 'sha1Cert': [sha1Cert],
    if ($fields != null) 'fields': [$fields],
  };

  const _url = 'v1/projects';

  final _response = await _requester.request(
    _url,
    'GET',
    queryParams: _queryParams,
  );
  return GoogleCloudIdentitytoolkitV1GetProjectConfigResponse.fromJson(
      _response as core.Map<core.String, core.dynamic>);
}