Module: Google::Iam::Credentials::V1::IAMCredentials::Paths

Extended by:
Paths
Included in:
Client, Paths, Rest::Client
Defined in:
lib/google/iam/credentials/v1/iam_credentials/paths.rb

Overview

Path helper methods for the IAMCredentials API.

Instance Method Summary collapse

Instance Method Details

#service_account_path(project:, service_account:) ⇒ ::String

Create a fully-qualified ServiceAccount resource string.

The resource will be in the following format:

projects/{project}/serviceAccounts/{service_account}

Parameters:

  • project (String)
  • service_account (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


38
39
40
41
42
# File 'lib/google/iam/credentials/v1/iam_credentials/paths.rb', line 38

def  project:, service_account:
  raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"

  "projects/#{project}/serviceAccounts/#{}"
end