def ListServices(args: 'argparse.Namespace') -> None:
  """List active GCP services (APIs) for a project.

  Args:
    args (argparse.Namespace): Arguments from ArgumentParser.

  Raises:
    AttributeError: If no project_id was provided and none was inferred
        from the gcloud environment.
  """

  AssignProjectID(args)

  apis = gcp_monitoring.GoogleCloudMonitoring(args.project)
  results = apis.ActiveServices()
  logger.info('Found {0:d} APIs:'.format(len(results)))
  sorted_apis = sorted(results.items(), key=lambda x: x[1], reverse=True)
  for apiname, usage in sorted_apis:
    logger.info('{0:s}: {1:d}'.format(apiname, usage))
List active GCP services (APIs) for a project.

Args:
args (argparse.Namespace): Arguments from ArgumentParser.

Raises:
AttributeError: If no project_id was provided and none was inferred
from the gcloud environment.
tools/gcp_cli.py